def main(): parser = OptionParser([SceneOps(), AlgorithmOps(), ThresholdOps()]) scenes, algorithms, threshold = parser.parse_args() # delay imports to speed up usage response from toolkit.evaluations import error_heatmaps error_heatmaps.plot(algorithms, scenes, thresh=threshold)
def main(): parser = OptionParser([SceneOps(), AlgorithmOps(with_gt=True), MetaAlgorithmOps(default=[])]) scenes, algorithms, meta_algorithms, compute_meta_algos = parser.parse_args() # delay imports to speed up usage response from toolkit import settings from toolkit.algorithms import MetaAlgorithm from toolkit.utils import log, misc, point_cloud if compute_meta_algos and meta_algorithms: MetaAlgorithm.prepare_meta_algorithms(meta_algorithms, algorithms, scenes) algorithms += meta_algorithms for scene in scenes: center_view = scene.get_center_view() for algorithm in algorithms: if algorithm.get_name() == "gt": disp_map = scene.get_gt() else: disp_map = misc.get_algo_result(algorithm, scene) log.info("Creating point cloud for scene '%s' with '%s' disparity map." % (scene.get_name(), algorithm.get_name())) pc = point_cloud.convert(scene, disp_map, center_view) file_name = "%s_%s.ply" % (scene.get_name(), algorithm.get_name()) file_path = op.join(settings.EVAL_PATH, "point_clouds", file_name) log.info("Saving point cloud to: %s" % file_path) point_cloud.save(pc, file_path)
def main(): parser = OptionParser([ SceneOps(), AlgorithmOps(), MetricOps(), VisualizationOps(), OverwriteOps(), MetaAlgorithmOps(default=[]) ]) scenes, algorithms, metrics, with_vis, add_to_existing, meta_algorithms, compute_meta_algos = parser.parse_args( ) # delay import to speed up usage response from toolkit import settings from toolkit.algorithms import MetaAlgorithm from toolkit.evaluations import submission_evaluation from toolkit.utils import misc if compute_meta_algos and meta_algorithms: MetaAlgorithm.prepare_meta_algorithms(meta_algorithms, algorithms, scenes) algorithms += meta_algorithms for algorithm in algorithms: evaluation_output_path = op.join(settings.ALGO_EVAL_PATH, algorithm.get_name()) algorithm_input_path = misc.get_path_to_algo_data(algorithm) submission_evaluation.evaluate( scenes=scenes, metrics=metrics, visualize=with_vis, evaluation_output_path=evaluation_output_path, algorithm_input_path=algorithm_input_path, add_to_existing_results=add_to_existing)
def main(): parser = OptionParser([ AlgorithmOps(), SceneOps(), MetaAlgorithmOps(with_load_argument=False) ]) algorithms, scenes, meta_algorithms = parser.parse_args() from toolkit.algorithms import MetaAlgorithm MetaAlgorithm.prepare_meta_algorithms(meta_algorithms, algorithms, scenes)
def main(): parser = OptionParser([SceneOps(), AlgorithmOps(), MetaAlgorithmOps(default=[])]) scenes, algorithms, meta_algorithms, compute_meta_algos = parser.parse_args() # delay imports to speed up usage response from toolkit.algorithms import MetaAlgorithm from toolkit.evaluations import bad_pix_series if compute_meta_algos and meta_algorithms: MetaAlgorithm.prepare_meta_algorithms(meta_algorithms, algorithms, scenes) bad_pix_series.plot(algorithms+meta_algorithms, scenes)
def main(): parser = OptionParser([SceneOps(), AlgorithmOps(), MetricOps(), MetaAlgorithmOps(default=[])]) scenes, algorithms, metrics, meta_algorithms, compute_meta_algos = parser.parse_args() # delay imports to speed up usage response from toolkit.algorithms import MetaAlgorithm from toolkit.evaluations import metric_overviews if compute_meta_algos and meta_algorithms: MetaAlgorithm.prepare_meta_algorithms(meta_algorithms, algorithms, scenes) metric_overviews.plot_general_overview(algorithms+meta_algorithms, scenes, metrics)
def main(): parser = OptionParser([SceneOps(), AlgorithmOps(), MetaAlgorithmOps()]) scenes, algorithms, meta_algorithms, compute_meta_algos = parser.parse_args( ) # delay imports to speed up usage response from toolkit.algorithms import MetaAlgorithm from toolkit.evaluations import meta_algo_comparisons if compute_meta_algos and meta_algorithms: MetaAlgorithm.prepare_meta_algorithms(meta_algorithms, algorithms, scenes) for meta_algorithm in meta_algorithms: meta_algo_comparisons.plot(algorithms, scenes, meta_algorithm)
def main(): parser = OptionParser( [AlgorithmOps(), SceneOps(), MetaAlgorithmOps(default=[])]) algorithms, scenes, meta_algorithms, compute_meta_algos = parser.parse_args( ) # delay imports to speed up usage response from toolkit.algorithms import MetaAlgorithm from toolkit.evaluations import pairwise_algo_comparisons if compute_meta_algos and meta_algorithms: MetaAlgorithm.prepare_meta_algorithms(meta_algorithms, algorithms, scenes) pairwise_algo_comparisons.plot_pairwise_comparisons( algorithms + meta_algorithms, scenes)
def main(): scenes = OptionParser([SceneOps()]).parse_args() for scene in scenes: offset = scene.compute_offset() print "%s: %0.3f" % (scene, offset)