529c4bc269f6c3a265d49b97393cbc6ecbcf5f94,python/hypertools/plot/plot.py,,plot,#Any#,26
Before Change
x_reshaped = [[] for i in categories]
for idx,point in enumerate(point_colors):
x_reshaped[categories.index(point)].append(x_stacked[idx])
x = [np.vstack(i) for i in x_reshaped]
if "style" in kwargs:
sns.set(style=kwargs["style"])
del kwargs["style"]
After Change
////HYPERTOOLS-SPECIFIC ARG PARSING////
if "n_clusters" in kwargs:
n_clusters=kwargs["n_clusters"]
if "ndims" in kwargs:
ndims = kwargs["ndims"]
else:
ndims = 3
cluster_labels = get_clusters(x, ndims, n_clusters)
x = reshape_data(x,cluster_labels)
del kwargs["n_clusters"]
if "point_colors" in kwargs:
warnings.warn("n_clusters overrides point_colors, ignoring point_colors.")
del kwargs["point_colors"]
// handle point_colors flag
if "point_colors" in kwargs:
point_colors=kwargs["point_colors"]
del kwargs["point_colors"]
In pattern: SUPERPATTERN
Frequency: 4
Non-data size: 7
Instances Project Name: ContextLab/hypertools
Commit Name: 529c4bc269f6c3a265d49b97393cbc6ecbcf5f94
Time: 2016-12-22
Author: andrew.heusser@gmail.com
File Name: python/hypertools/plot/plot.py
Class Name:
Method Name: plot
Project Name: NifTK/NiftyNet
Commit Name: 2fd05c36d17abfb079cb21ebb830afc2159431ef
Time: 2017-05-24
Author: wenqi.li@ucl.ac.uk
File Name: nn/histogram_standardisation.py
Class Name:
Method Name: check_modalities_to_train
Project Name: ContextLab/hypertools
Commit Name: 7c2673280add4356814a56e5a4253bd959630e95
Time: 2016-12-22
Author: andrew.heusser@gmail.com
File Name: python/hypertools/plot/plot.py
Class Name:
Method Name: plot
Project Name: kengz/SLM-Lab
Commit Name: b30d6c0a8573cb908189563d8fdef42df4d7b638
Time: 2019-09-18
Author: kengzwl@gmail.com
File Name: bin/plot_benchmark.py
Class Name:
Method Name: plot_env