def visualizing(path, amount, threshold, ccore): sample = read_sample(path) bsas_instance = bsas(sample, amount, threshold, ccore=ccore) bsas_instance.process() bsas_visualizer.show_clusters(sample, bsas_instance.get_clusters(), bsas_instance.get_representatives())
def template_clustering(path, amount, threshold, **kwargs): metric = kwargs.get('metric', distance_metric(type_metric.EUCLIDEAN_SQUARE)); ccore = kwargs.get('ccore', False); draw = kwargs.get('draw', True); sample = read_sample(path); print("Sample: ", path); mbsas_instance = mbsas(sample, amount, threshold, ccore=ccore, metric=metric); mbsas_instance.process(); clusters = mbsas_instance.get_clusters(); representatives = mbsas_instance.get_representatives(); if draw is True: bsas_visualizer.show_clusters(sample, clusters, representatives);
def template_clustering(path, amount, threshold, **kwargs): metric = kwargs.get('metric', distance_metric(type_metric.EUCLIDEAN_SQUARE)); ccore = kwargs.get('ccore', False); draw = kwargs.get('draw', True); sample = read_sample(path); print("Sample: ", path); bsas_instance = bsas(sample, amount, threshold, ccore=ccore, metric=metric); bsas_instance.process(); clusters = bsas_instance.get_clusters(); representatives = bsas_instance.get_representatives(); if draw is True: bsas_visualizer.show_clusters(sample, clusters, representatives);
def template_clustering(path, threshold1, threshold2, **kwargs): metric = kwargs.get('metric', distance_metric(type_metric.EUCLIDEAN_SQUARE)) ccore = kwargs.get('ccore', False) draw = kwargs.get('draw', True) sample = read_sample(path) print("Sample: ", path) ttsas_instance = ttsas(sample, threshold1, threshold2, ccore=ccore, metric=metric) ttsas_instance.process() clusters = ttsas_instance.get_clusters() representatives = ttsas_instance.get_representatives() if draw is True: bsas_visualizer.show_clusters(sample, clusters, representatives)
def visualizing(path, amount, threshold, ccore): sample = read_sample(path); bsas_instance = bsas(sample, amount, threshold, ccore=ccore); bsas_instance.process(); bsas_visualizer.show_clusters(sample, bsas_instance.get_clusters(), bsas_instance.get_representatives());