megadetector 5.0.10__py3-none-any.whl → 5.0.12__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of megadetector might be problematic. Click here for more details.
- {api → megadetector/api}/batch_processing/api_core/batch_service/score.py +2 -2
- {api → megadetector/api}/synchronous/api_core/animal_detection_api/api_backend.py +1 -1
- {api → megadetector/api}/synchronous/api_core/animal_detection_api/api_frontend.py +1 -1
- {classification → megadetector/classification}/analyze_failed_images.py +3 -3
- {classification → megadetector/classification}/cache_batchapi_outputs.py +1 -1
- {classification → megadetector/classification}/create_classification_dataset.py +1 -1
- {classification → megadetector/classification}/crop_detections.py +1 -1
- {classification → megadetector/classification}/detect_and_crop.py +5 -5
- {classification → megadetector/classification}/evaluate_model.py +1 -1
- {classification → megadetector/classification}/json_to_azcopy_list.py +2 -2
- {classification → megadetector/classification}/json_validator.py +13 -9
- {classification → megadetector/classification}/map_classification_categories.py +1 -1
- {classification → megadetector/classification}/merge_classification_detection_output.py +1 -1
- {classification → megadetector/classification}/run_classifier.py +2 -1
- {classification → megadetector/classification}/train_classifier.py +8 -6
- {classification → megadetector/classification}/train_classifier_tf.py +10 -9
- {classification → megadetector/classification}/train_utils.py +3 -2
- {data_management → megadetector/data_management}/camtrap_dp_to_coco.py +4 -3
- {data_management → megadetector/data_management}/cct_json_utils.py +2 -2
- {data_management → megadetector/data_management}/cct_to_md.py +1 -1
- {data_management → megadetector/data_management}/coco_to_labelme.py +1 -1
- {data_management → megadetector/data_management}/coco_to_yolo.py +1 -1
- {data_management → megadetector/data_management}/databases/integrity_check_json_db.py +2 -2
- {data_management → megadetector/data_management}/get_image_sizes.py +4 -3
- {data_management → megadetector/data_management}/importers/auckland_doc_test_to_json.py +6 -5
- {data_management → megadetector/data_management}/importers/auckland_doc_to_json.py +4 -3
- {data_management → megadetector/data_management}/importers/awc_to_json.py +6 -4
- {data_management → megadetector/data_management}/importers/bellevue_to_json.py +3 -3
- {data_management → megadetector/data_management}/importers/cacophony-thermal-importer.py +4 -4
- {data_management → megadetector/data_management}/importers/carrizo_shrubfree_2018.py +5 -4
- {data_management → megadetector/data_management}/importers/carrizo_trail_cam_2017.py +8 -6
- {data_management → megadetector/data_management}/importers/cct_field_adjustments.py +2 -1
- {data_management → megadetector/data_management}/importers/channel_islands_to_cct.py +2 -2
- {data_management → megadetector/data_management}/importers/ena24_to_json.py +6 -5
- {data_management → megadetector/data_management}/importers/filenames_to_json.py +2 -1
- {data_management → megadetector/data_management}/importers/helena_to_cct.py +7 -6
- {data_management → megadetector/data_management}/importers/idaho-camera-traps.py +6 -6
- {data_management → megadetector/data_management}/importers/idfg_iwildcam_lila_prep.py +4 -4
- {data_management → megadetector/data_management}/importers/jb_csv_to_json.py +1 -1
- {data_management → megadetector/data_management}/importers/missouri_to_json.py +4 -3
- {data_management → megadetector/data_management}/importers/noaa_seals_2019.py +2 -2
- {data_management → megadetector/data_management}/importers/pc_to_json.py +5 -5
- {data_management → megadetector/data_management}/importers/prepare-noaa-fish-data-for-lila.py +3 -3
- {data_management → megadetector/data_management}/importers/prepare_zsl_imerit.py +3 -3
- {data_management → megadetector/data_management}/importers/rspb_to_json.py +2 -2
- {data_management → megadetector/data_management}/importers/save_the_elephants_survey_A.py +4 -4
- {data_management → megadetector/data_management}/importers/save_the_elephants_survey_B.py +6 -9
- {data_management → megadetector/data_management}/importers/snapshot_safari_importer.py +4 -4
- {data_management → megadetector/data_management}/importers/snapshot_safari_importer_reprise.py +2 -2
- {data_management → megadetector/data_management}/importers/snapshot_serengeti_lila.py +4 -4
- {data_management → megadetector/data_management}/importers/timelapse_csv_set_to_json.py +3 -3
- {data_management → megadetector/data_management}/importers/ubc_to_json.py +3 -3
- {data_management → megadetector/data_management}/importers/umn_to_json.py +2 -2
- {data_management → megadetector/data_management}/importers/wellington_to_json.py +3 -3
- {data_management → megadetector/data_management}/importers/wi_to_json.py +3 -2
- {data_management → megadetector/data_management}/labelme_to_coco.py +6 -7
- {data_management → megadetector/data_management}/labelme_to_yolo.py +2 -2
- {data_management → megadetector/data_management}/lila/add_locations_to_island_camera_traps.py +4 -4
- {data_management → megadetector/data_management}/lila/create_lila_blank_set.py +10 -9
- {data_management → megadetector/data_management}/lila/create_lila_test_set.py +3 -2
- {data_management → megadetector/data_management}/lila/create_links_to_md_results_files.py +1 -1
- {data_management → megadetector/data_management}/lila/download_lila_subset.py +5 -4
- {data_management → megadetector/data_management}/lila/generate_lila_per_image_labels.py +6 -5
- {data_management → megadetector/data_management}/lila/get_lila_annotation_counts.py +2 -2
- {data_management → megadetector/data_management}/lila/get_lila_image_counts.py +2 -1
- {data_management → megadetector/data_management}/lila/lila_common.py +5 -5
- {data_management → megadetector/data_management}/lila/test_lila_metadata_urls.py +2 -2
- {data_management → megadetector/data_management}/ocr_tools.py +6 -6
- {data_management → megadetector/data_management}/read_exif.py +2 -2
- {data_management → megadetector/data_management}/remap_coco_categories.py +1 -1
- {data_management → megadetector/data_management}/remove_exif.py +1 -1
- {data_management → megadetector/data_management}/resize_coco_dataset.py +4 -4
- {data_management → megadetector/data_management}/wi_download_csv_to_coco.py +3 -3
- {data_management → megadetector/data_management}/yolo_output_to_md_output.py +5 -5
- {data_management → megadetector/data_management}/yolo_to_coco.py +9 -9
- {detection → megadetector/detection}/process_video.py +9 -10
- {detection → megadetector/detection}/pytorch_detector.py +12 -8
- {detection → megadetector/detection}/run_detector.py +6 -6
- {detection → megadetector/detection}/run_detector_batch.py +12 -12
- {detection → megadetector/detection}/run_inference_with_yolov5_val.py +12 -12
- {detection → megadetector/detection}/run_tiled_inference.py +8 -9
- {detection → megadetector/detection}/tf_detector.py +3 -2
- {detection → megadetector/detection}/video_utils.py +2 -2
- {api/batch_processing → megadetector}/postprocessing/add_max_conf.py +1 -1
- {api/batch_processing → megadetector}/postprocessing/categorize_detections_by_size.py +1 -1
- {api/batch_processing → megadetector}/postprocessing/combine_api_outputs.py +1 -1
- {api/batch_processing → megadetector}/postprocessing/compare_batch_results.py +5 -5
- {api/batch_processing → megadetector}/postprocessing/convert_output_format.py +4 -5
- {api/batch_processing → megadetector}/postprocessing/load_api_results.py +1 -1
- {api/batch_processing → megadetector}/postprocessing/md_to_coco.py +3 -3
- {api/batch_processing → megadetector}/postprocessing/md_to_labelme.py +3 -3
- {api/batch_processing → megadetector}/postprocessing/merge_detections.py +1 -1
- {api/batch_processing → megadetector}/postprocessing/postprocess_batch_results.py +19 -21
- {api/batch_processing → megadetector}/postprocessing/remap_detection_categories.py +1 -1
- {api/batch_processing → megadetector}/postprocessing/render_detection_confusion_matrix.py +5 -6
- {api/batch_processing → megadetector}/postprocessing/repeat_detection_elimination/find_repeat_detections.py +3 -3
- {api/batch_processing → megadetector}/postprocessing/repeat_detection_elimination/remove_repeat_detections.py +3 -2
- {api/batch_processing → megadetector}/postprocessing/repeat_detection_elimination/repeat_detections_core.py +11 -11
- {api/batch_processing → megadetector}/postprocessing/separate_detections_into_folders.py +3 -4
- {api/batch_processing → megadetector}/postprocessing/subset_json_detector_output.py +2 -2
- {api/batch_processing → megadetector}/postprocessing/top_folders_to_bottom.py +1 -1
- {taxonomy_mapping → megadetector/taxonomy_mapping}/map_lila_taxonomy_to_wi_taxonomy.py +2 -2
- {taxonomy_mapping → megadetector/taxonomy_mapping}/map_new_lila_datasets.py +2 -6
- {taxonomy_mapping → megadetector/taxonomy_mapping}/preview_lila_taxonomy.py +6 -7
- {taxonomy_mapping → megadetector/taxonomy_mapping}/retrieve_sample_image.py +1 -1
- {taxonomy_mapping → megadetector/taxonomy_mapping}/simple_image_download.py +2 -1
- {taxonomy_mapping → megadetector/taxonomy_mapping}/species_lookup.py +1 -1
- {taxonomy_mapping → megadetector/taxonomy_mapping}/taxonomy_csv_checker.py +1 -1
- {taxonomy_mapping → megadetector/taxonomy_mapping}/validate_lila_category_mappings.py +1 -1
- {md_utils → megadetector/utils}/azure_utils.py +7 -3
- {md_utils → megadetector/utils}/directory_listing.py +1 -1
- {md_utils → megadetector/utils}/md_tests.py +29 -29
- {md_utils → megadetector/utils}/split_locations_into_train_val.py +1 -1
- {md_utils → megadetector/utils}/write_html_image_list.py +1 -1
- {md_visualization → megadetector/visualization}/render_images_with_thumbnails.py +3 -3
- {md_visualization → megadetector/visualization}/visualization_utils.py +6 -7
- {md_visualization → megadetector/visualization}/visualize_db.py +3 -4
- {md_visualization → megadetector/visualization}/visualize_detector_output.py +9 -10
- {megadetector-5.0.10.dist-info → megadetector-5.0.12.dist-info}/LICENSE +0 -0
- {megadetector-5.0.10.dist-info → megadetector-5.0.12.dist-info}/METADATA +12 -11
- megadetector-5.0.12.dist-info/RECORD +199 -0
- megadetector-5.0.12.dist-info/top_level.txt +1 -0
- api/batch_processing/data_preparation/manage_local_batch.py +0 -2391
- api/batch_processing/data_preparation/manage_video_batch.py +0 -327
- api/synchronous/api_core/animal_detection_api/data_management/annotations/annotation_constants.py +0 -47
- api/synchronous/api_core/animal_detection_api/detection/detector_training/copy_checkpoints.py +0 -43
- api/synchronous/api_core/animal_detection_api/detection/process_video.py +0 -543
- api/synchronous/api_core/animal_detection_api/detection/pytorch_detector.py +0 -304
- api/synchronous/api_core/animal_detection_api/detection/run_detector.py +0 -627
- api/synchronous/api_core/animal_detection_api/detection/run_detector_batch.py +0 -1029
- api/synchronous/api_core/animal_detection_api/detection/run_inference_with_yolov5_val.py +0 -581
- api/synchronous/api_core/animal_detection_api/detection/run_tiled_inference.py +0 -754
- api/synchronous/api_core/animal_detection_api/detection/tf_detector.py +0 -165
- api/synchronous/api_core/animal_detection_api/detection/video_utils.py +0 -495
- api/synchronous/api_core/animal_detection_api/md_utils/azure_utils.py +0 -174
- api/synchronous/api_core/animal_detection_api/md_utils/ct_utils.py +0 -262
- api/synchronous/api_core/animal_detection_api/md_utils/directory_listing.py +0 -251
- api/synchronous/api_core/animal_detection_api/md_utils/matlab_porting_tools.py +0 -97
- api/synchronous/api_core/animal_detection_api/md_utils/path_utils.py +0 -416
- api/synchronous/api_core/animal_detection_api/md_utils/process_utils.py +0 -110
- api/synchronous/api_core/animal_detection_api/md_utils/sas_blob_utils.py +0 -509
- api/synchronous/api_core/animal_detection_api/md_utils/string_utils.py +0 -59
- api/synchronous/api_core/animal_detection_api/md_utils/url_utils.py +0 -144
- api/synchronous/api_core/animal_detection_api/md_utils/write_html_image_list.py +0 -226
- api/synchronous/api_core/animal_detection_api/md_visualization/visualization_utils.py +0 -841
- detection/detector_training/model_main_tf2.py +0 -114
- docs/source/conf.py +0 -43
- megadetector-5.0.10.dist-info/RECORD +0 -224
- megadetector-5.0.10.dist-info/top_level.txt +0 -8
- {api → megadetector/api}/__init__.py +0 -0
- {api → megadetector/api}/batch_processing/__init__.py +0 -0
- {api → megadetector/api}/batch_processing/api_core/__init__.py +0 -0
- {api → megadetector/api}/batch_processing/api_core/batch_service/__init__.py +0 -0
- {api → megadetector/api}/batch_processing/api_core/server.py +0 -0
- {api → megadetector/api}/batch_processing/api_core/server_api_config.py +0 -0
- {api → megadetector/api}/batch_processing/api_core/server_app_config.py +0 -0
- {api → megadetector/api}/batch_processing/api_core/server_batch_job_manager.py +0 -0
- {api → megadetector/api}/batch_processing/api_core/server_job_status_table.py +0 -0
- {api → megadetector/api}/batch_processing/api_core/server_orchestration.py +0 -0
- {api → megadetector/api}/batch_processing/api_core/server_utils.py +0 -0
- {api → megadetector/api}/batch_processing/api_core_support/__init__.py +0 -0
- {api → megadetector/api}/batch_processing/api_core_support/aggregate_results_manually.py +0 -0
- {api → megadetector/api}/batch_processing/api_support/__init__.py +0 -0
- {api → megadetector/api}/batch_processing/api_support/summarize_daily_activity.py +0 -0
- {api → megadetector/api}/batch_processing/data_preparation/__init__.py +0 -0
- {api → megadetector/api}/batch_processing/integration/digiKam/setup.py +0 -0
- {api → megadetector/api}/batch_processing/integration/digiKam/xmp_integration.py +0 -0
- {api → megadetector/api}/batch_processing/integration/eMammal/test_scripts/config_template.py +0 -0
- {api → megadetector/api}/batch_processing/integration/eMammal/test_scripts/push_annotations_to_emammal.py +0 -0
- {api → megadetector/api}/batch_processing/integration/eMammal/test_scripts/select_images_for_testing.py +0 -0
- {api/batch_processing/postprocessing → megadetector/api/synchronous}/__init__.py +0 -0
- {api/synchronous → megadetector/api/synchronous/api_core/animal_detection_api}/__init__.py +0 -0
- {api → megadetector/api}/synchronous/api_core/animal_detection_api/config.py +0 -0
- {api/synchronous/api_core/animal_detection_api → megadetector/api/synchronous/api_core/tests}/__init__.py +0 -0
- {api → megadetector/api}/synchronous/api_core/tests/load_test.py +0 -0
- {api/synchronous/api_core/tests → megadetector/classification}/__init__.py +0 -0
- {classification → megadetector/classification}/aggregate_classifier_probs.py +0 -0
- {classification → megadetector/classification}/csv_to_json.py +0 -0
- {classification → megadetector/classification}/efficientnet/__init__.py +0 -0
- {classification → megadetector/classification}/efficientnet/model.py +0 -0
- {classification → megadetector/classification}/efficientnet/utils.py +0 -0
- {classification → megadetector/classification}/identify_mislabeled_candidates.py +0 -0
- {classification → megadetector/classification}/prepare_classification_script.py +0 -0
- {classification → megadetector/classification}/prepare_classification_script_mc.py +0 -0
- {classification → megadetector/classification}/save_mislabeled.py +0 -0
- {classification → megadetector/data_management}/__init__.py +0 -0
- {data_management → megadetector/data_management/annotations}/__init__.py +0 -0
- {data_management → megadetector/data_management}/annotations/annotation_constants.py +0 -0
- {data_management → megadetector/data_management}/cct_to_wi.py +0 -0
- {data_management/annotations → megadetector/data_management/databases}/__init__.py +0 -0
- {data_management → megadetector/data_management}/databases/add_width_and_height_to_db.py +0 -0
- {data_management → megadetector/data_management}/databases/combine_coco_camera_traps_files.py +0 -0
- {data_management → megadetector/data_management}/databases/subset_json_db.py +0 -0
- {data_management → megadetector/data_management}/generate_crops_from_cct.py +0 -0
- {data_management → megadetector/data_management}/importers/add_nacti_sizes.py +0 -0
- {data_management → megadetector/data_management}/importers/add_timestamps_to_icct.py +0 -0
- {data_management → megadetector/data_management}/importers/animl_results_to_md_results.py +0 -0
- {data_management → megadetector/data_management}/importers/eMammal/copy_and_unzip_emammal.py +0 -0
- {data_management → megadetector/data_management}/importers/eMammal/eMammal_helpers.py +0 -0
- {data_management → megadetector/data_management}/importers/eMammal/make_eMammal_json.py +0 -0
- {data_management → megadetector/data_management}/importers/mcgill_to_json.py +0 -0
- {data_management → megadetector/data_management}/importers/nacti_fieldname_adjustments.py +0 -0
- {data_management → megadetector/data_management}/importers/plot_wni_giraffes.py +0 -0
- {data_management → megadetector/data_management}/importers/snapshotserengeti/make_full_SS_json.py +0 -0
- {data_management → megadetector/data_management}/importers/snapshotserengeti/make_per_season_SS_json.py +0 -0
- {data_management → megadetector/data_management}/importers/sulross_get_exif.py +0 -0
- {data_management → megadetector/data_management}/importers/zamba_results_to_md_results.py +0 -0
- {data_management/databases → megadetector/data_management/lila}/__init__.py +0 -0
- {data_management → megadetector/data_management}/lila/add_locations_to_nacti.py +0 -0
- {data_management/lila → megadetector/detection}/__init__.py +0 -0
- {detection → megadetector/detection/detector_training}/__init__.py +0 -0
- {api/synchronous/api_core/animal_detection_api → megadetector}/detection/detector_training/model_main_tf2.py +0 -0
- {detection/detector_training → megadetector/postprocessing}/__init__.py +0 -0
- {md_utils → megadetector/taxonomy_mapping}/__init__.py +0 -0
- {taxonomy_mapping → megadetector/taxonomy_mapping}/prepare_lila_taxonomy_release.py +0 -0
- {taxonomy_mapping → megadetector/taxonomy_mapping}/taxonomy_graph.py +0 -0
- {md_visualization → megadetector/utils}/__init__.py +0 -0
- {md_utils → megadetector/utils}/ct_utils.py +0 -0
- {md_utils → megadetector/utils}/path_utils.py +0 -0
- {md_utils → megadetector/utils}/process_utils.py +0 -0
- {md_utils → megadetector/utils}/sas_blob_utils.py +0 -0
- {md_utils → megadetector/utils}/string_utils.py +0 -0
- {md_utils → megadetector/utils}/url_utils.py +0 -0
- {taxonomy_mapping → megadetector/visualization}/__init__.py +0 -0
- {md_visualization → megadetector/visualization}/plot_utils.py +0 -0
- {megadetector-5.0.10.dist-info → megadetector-5.0.12.dist-info}/WHEEL +0 -0
|
@@ -55,11 +55,11 @@ import json
|
|
|
55
55
|
|
|
56
56
|
from tqdm import tqdm
|
|
57
57
|
|
|
58
|
-
from
|
|
59
|
-
from
|
|
60
|
-
from
|
|
61
|
-
from data_management import yolo_output_to_md_output
|
|
62
|
-
from detection.run_detector import try_download_known_detector
|
|
58
|
+
from megadetector.utils import path_utils
|
|
59
|
+
from megadetector.utils import process_utils
|
|
60
|
+
from megadetector.utils import string_utils
|
|
61
|
+
from megadetector.data_management import yolo_output_to_md_output
|
|
62
|
+
from megadetector.detection.run_detector import try_download_known_detector
|
|
63
63
|
|
|
64
64
|
default_image_size_with_augmentation = int(1280 * 1.3)
|
|
65
65
|
default_image_size_with_no_augmentation = 1280
|
|
@@ -548,7 +548,7 @@ def run_inference_with_yolo_val(options):
|
|
|
548
548
|
#%% Command-line driver
|
|
549
549
|
|
|
550
550
|
import argparse
|
|
551
|
-
from
|
|
551
|
+
from megadetector.utils.ct_utils import args_to_object
|
|
552
552
|
|
|
553
553
|
def main():
|
|
554
554
|
|
|
@@ -811,8 +811,8 @@ if False:
|
|
|
811
811
|
postprocessing_output_folder = os.path.join(output_folder,'yolo-val-preview')
|
|
812
812
|
md_json_file = options.output_file
|
|
813
813
|
|
|
814
|
-
from
|
|
815
|
-
PostProcessingOptions, process_batch_results
|
|
814
|
+
from megadetector.postprocessing.postprocess_batch_results import \
|
|
815
|
+
PostProcessingOptions, process_batch_results
|
|
816
816
|
|
|
817
817
|
with open(md_json_file,'r') as f:
|
|
818
818
|
d = json.load(f)
|
|
@@ -839,7 +839,7 @@ if False:
|
|
|
839
839
|
os.makedirs(output_base, exist_ok=True)
|
|
840
840
|
print('Processing to {}'.format(output_base))
|
|
841
841
|
|
|
842
|
-
pp_options.
|
|
842
|
+
pp_options.md_results_file = md_json_file
|
|
843
843
|
pp_options.output_dir = output_base
|
|
844
844
|
ppresults = process_batch_results(pp_options)
|
|
845
845
|
html_output_file = ppresults.output_html_file
|
|
@@ -853,8 +853,8 @@ if False:
|
|
|
853
853
|
|
|
854
854
|
import itertools
|
|
855
855
|
|
|
856
|
-
from
|
|
857
|
-
BatchComparisonOptions,PairwiseBatchComparisonOptions,compare_batch_results
|
|
856
|
+
from megadetector.postprocessing.compare_batch_results import \
|
|
857
|
+
BatchComparisonOptions,PairwiseBatchComparisonOptions,compare_batch_results
|
|
858
858
|
|
|
859
859
|
options = BatchComparisonOptions()
|
|
860
860
|
|
|
@@ -913,5 +913,5 @@ if False:
|
|
|
913
913
|
|
|
914
914
|
results = compare_batch_results(options)
|
|
915
915
|
|
|
916
|
-
from
|
|
916
|
+
from megadetector.utils.path_utils import open_file
|
|
917
917
|
open_file(results.html_output_file)
|
|
@@ -29,15 +29,14 @@ import json
|
|
|
29
29
|
|
|
30
30
|
from tqdm import tqdm
|
|
31
31
|
|
|
32
|
-
from detection.run_inference_with_yolov5_val import YoloInferenceOptions,run_inference_with_yolo_val
|
|
33
|
-
from detection.run_detector_batch import load_and_run_detector_batch,write_results_to_file
|
|
34
|
-
from detection.run_detector import try_download_known_detector
|
|
35
|
-
|
|
36
32
|
import torch
|
|
37
33
|
from torchvision import ops
|
|
38
34
|
|
|
39
|
-
from
|
|
40
|
-
from
|
|
35
|
+
from megadetector.detection.run_inference_with_yolov5_val import YoloInferenceOptions,run_inference_with_yolo_val
|
|
36
|
+
from megadetector.detection.run_detector_batch import load_and_run_detector_batch,write_results_to_file
|
|
37
|
+
from megadetector.detection.run_detector import try_download_known_detector
|
|
38
|
+
from megadetector.utils import path_utils
|
|
39
|
+
from megadetector.visualization import visualization_utils as vis_utils
|
|
41
40
|
|
|
42
41
|
default_patch_overlap = 0.5
|
|
43
42
|
patch_jpeg_quality = 95
|
|
@@ -821,8 +820,8 @@ if False:
|
|
|
821
820
|
|
|
822
821
|
#%% Preview tiled inference
|
|
823
822
|
|
|
824
|
-
from
|
|
825
|
-
PostProcessingOptions, process_batch_results
|
|
823
|
+
from megadetector.postprocessing.postprocess_batch_results import \
|
|
824
|
+
PostProcessingOptions, process_batch_results
|
|
826
825
|
|
|
827
826
|
options = PostProcessingOptions()
|
|
828
827
|
options.image_base_dir = image_folder
|
|
@@ -843,7 +842,7 @@ if False:
|
|
|
843
842
|
|
|
844
843
|
print('Processing post-RDE to {}'.format(preview_base))
|
|
845
844
|
|
|
846
|
-
options.
|
|
845
|
+
options.md_results_file = output_file
|
|
847
846
|
options.output_dir = preview_base
|
|
848
847
|
ppresults = process_batch_results(options)
|
|
849
848
|
html_output_file = ppresults.output_html_file
|
|
@@ -10,8 +10,9 @@ Module containing the class TFDetector, for loading and running a TensorFlow det
|
|
|
10
10
|
|
|
11
11
|
import numpy as np
|
|
12
12
|
|
|
13
|
-
from detection.run_detector import
|
|
14
|
-
|
|
13
|
+
from megadetector.detection.run_detector import \
|
|
14
|
+
CONF_DIGITS, COORD_DIGITS, FAILURE_INFER
|
|
15
|
+
from megadetector.utils.ct_utils import truncate_float
|
|
15
16
|
|
|
16
17
|
import tensorflow.compat.v1 as tf
|
|
17
18
|
|
|
@@ -19,8 +19,8 @@ from multiprocessing.pool import Pool
|
|
|
19
19
|
from tqdm import tqdm
|
|
20
20
|
from functools import partial
|
|
21
21
|
|
|
22
|
-
from
|
|
23
|
-
from
|
|
22
|
+
from megadetector.utils import path_utils
|
|
23
|
+
from megadetector.visualization import visualization_utils as vis_utils
|
|
24
24
|
|
|
25
25
|
default_fourcc = 'h264'
|
|
26
26
|
|
|
@@ -116,7 +116,7 @@ def categorize_detections_by_size(input_file,output_file=None,options=None):
|
|
|
116
116
|
(d['category'] not in options.categories_to_separate):
|
|
117
117
|
continue
|
|
118
118
|
|
|
119
|
-
# https://github.com/agentmorris/MegaDetector/tree/
|
|
119
|
+
# https://github.com/agentmorris/MegaDetector/tree/main/megadetector/api/batch_processing#detector-outputs
|
|
120
120
|
w = d['bbox'][2]
|
|
121
121
|
h = d['bbox'][3]
|
|
122
122
|
detection_size = w*h
|
|
@@ -11,7 +11,7 @@ writing the results to another .json file.
|
|
|
11
11
|
|
|
12
12
|
File format:
|
|
13
13
|
|
|
14
|
-
https://github.com/agentmorris/MegaDetector/tree/
|
|
14
|
+
https://github.com/agentmorris/MegaDetector/tree/main/megadetector/api/batch_processing#batch-processing-api-output-format
|
|
15
15
|
|
|
16
16
|
Command-line use:
|
|
17
17
|
|
|
@@ -30,9 +30,9 @@ from functools import partial
|
|
|
30
30
|
from multiprocessing.pool import ThreadPool
|
|
31
31
|
from multiprocessing.pool import Pool
|
|
32
32
|
|
|
33
|
-
from
|
|
34
|
-
from
|
|
35
|
-
from
|
|
33
|
+
from megadetector.visualization import visualization_utils
|
|
34
|
+
from megadetector.utils.write_html_image_list import write_html_image_list
|
|
35
|
+
from megadetector.utils import path_utils
|
|
36
36
|
|
|
37
37
|
|
|
38
38
|
#%% Constants and support classes
|
|
@@ -833,7 +833,7 @@ if False:
|
|
|
833
833
|
|
|
834
834
|
results = n_way_comparison(filenames,options,detection_thresholds,rendering_thresholds=rendering_thresholds)
|
|
835
835
|
|
|
836
|
-
from
|
|
836
|
+
from megadetector.utils.path_utils import open_file
|
|
837
837
|
open_file(results.html_output_file)
|
|
838
838
|
|
|
839
839
|
|
|
@@ -859,7 +859,7 @@ if False:
|
|
|
859
859
|
|
|
860
860
|
results = n_way_comparison(filenames,options,detection_thresholds,rendering_thresholds=None)
|
|
861
861
|
|
|
862
|
-
from
|
|
862
|
+
from megadetector.utils.path_utils import open_file
|
|
863
863
|
open_file(results.html_output_file)
|
|
864
864
|
|
|
865
865
|
|
|
@@ -21,10 +21,9 @@ import os
|
|
|
21
21
|
|
|
22
22
|
from tqdm import tqdm
|
|
23
23
|
|
|
24
|
-
from
|
|
25
|
-
from data_management.annotations import annotation_constants
|
|
26
|
-
|
|
27
|
-
from md_utils import ct_utils
|
|
24
|
+
from megadetector.postprocessing.load_api_results import load_api_results_csv
|
|
25
|
+
from megadetector.data_management.annotations import annotation_constants
|
|
26
|
+
from megadetector.utils import ct_utils
|
|
28
27
|
|
|
29
28
|
CONF_DIGITS = 3
|
|
30
29
|
|
|
@@ -242,7 +241,7 @@ def convert_csv_to_json(input_path,output_path=None,overwrite=True):
|
|
|
242
241
|
|
|
243
242
|
# Format spec:
|
|
244
243
|
#
|
|
245
|
-
# https://github.com/agentmorris/MegaDetector/tree/
|
|
244
|
+
# https://github.com/agentmorris/MegaDetector/tree/main/megadetector/api/batch_processing
|
|
246
245
|
|
|
247
246
|
print('Loading csv results...')
|
|
248
247
|
df = load_api_results_csv(input_path)
|
|
@@ -17,7 +17,7 @@ import uuid
|
|
|
17
17
|
|
|
18
18
|
from tqdm import tqdm
|
|
19
19
|
|
|
20
|
-
from
|
|
20
|
+
from megadetector.visualization import visualization_utils as vis_utils
|
|
21
21
|
|
|
22
22
|
default_confidence_threshold = 0.15
|
|
23
23
|
|
|
@@ -231,7 +231,7 @@ if False:
|
|
|
231
231
|
|
|
232
232
|
#%% Preview the resulting file
|
|
233
233
|
|
|
234
|
-
from
|
|
234
|
+
from megadetector.visualization import visualize_db
|
|
235
235
|
options = visualize_db.DbVizOptions()
|
|
236
236
|
options.parallelize_rendering = True
|
|
237
237
|
options.viz_size = (900, -1)
|
|
@@ -241,7 +241,7 @@ if False:
|
|
|
241
241
|
os.path.expanduser('~/tmp/md_to_coco_preview'),
|
|
242
242
|
image_folder,options)
|
|
243
243
|
|
|
244
|
-
from
|
|
244
|
+
from megadetector.utils import path_utils # noqa
|
|
245
245
|
path_utils.open_file(html_file)
|
|
246
246
|
|
|
247
247
|
|
|
@@ -24,9 +24,9 @@ from multiprocessing.pool import Pool
|
|
|
24
24
|
from multiprocessing.pool import ThreadPool
|
|
25
25
|
from functools import partial
|
|
26
26
|
|
|
27
|
-
from
|
|
28
|
-
from
|
|
29
|
-
from detection.run_detector import DEFAULT_DETECTOR_LABEL_MAP
|
|
27
|
+
from megadetector.visualization.visualization_utils import open_image
|
|
28
|
+
from megadetector.utils.ct_utils import truncate_float
|
|
29
|
+
from megadetector.detection.run_detector import DEFAULT_DETECTOR_LABEL_MAP
|
|
30
30
|
|
|
31
31
|
output_precision = 3
|
|
32
32
|
default_confidence_threshold = 0.15
|
|
@@ -13,7 +13,7 @@ Given a .json or .csv file containing MD results, do one or more of the followin
|
|
|
13
13
|
|
|
14
14
|
Ground truth, if available, must be in COCO Camera Traps format:
|
|
15
15
|
|
|
16
|
-
https://github.com/agentmorris/MegaDetector/blob/main/data_management/README.md#coco-camera-traps-format
|
|
16
|
+
https://github.com/agentmorris/MegaDetector/blob/main/megadetector/data_management/README.md#coco-camera-traps-format
|
|
17
17
|
|
|
18
18
|
"""
|
|
19
19
|
|
|
@@ -44,16 +44,14 @@ import pandas as pd
|
|
|
44
44
|
from sklearn.metrics import precision_recall_curve, confusion_matrix, average_precision_score
|
|
45
45
|
from tqdm import tqdm
|
|
46
46
|
|
|
47
|
-
import
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
from
|
|
51
|
-
from
|
|
52
|
-
from data_management.cct_json_utils import (CameraTrapJsonUtils, IndexedJsonDb)
|
|
53
|
-
from
|
|
54
|
-
from
|
|
55
|
-
|
|
56
|
-
from detection.run_detector import get_typical_confidence_threshold_from_results
|
|
47
|
+
from megadetector.visualization import visualization_utils as vis_utils
|
|
48
|
+
from megadetector.visualization import plot_utils
|
|
49
|
+
from megadetector.utils.write_html_image_list import write_html_image_list
|
|
50
|
+
from megadetector.utils import path_utils
|
|
51
|
+
from megadetector.utils.ct_utils import args_to_object, sets_overlap
|
|
52
|
+
from megadetector.data_management.cct_json_utils import (CameraTrapJsonUtils, IndexedJsonDb)
|
|
53
|
+
from megadetector.postprocessing.load_api_results import load_api_results
|
|
54
|
+
from megadetector.detection.run_detector import get_typical_confidence_threshold_from_results
|
|
57
55
|
|
|
58
56
|
warnings.filterwarnings('ignore', '(Possibly )?corrupt EXIF data', UserWarning)
|
|
59
57
|
|
|
@@ -394,7 +392,7 @@ def _render_bounding_boxes(
|
|
|
394
392
|
Renders detection bounding boxes on a single image.
|
|
395
393
|
|
|
396
394
|
This is an internal function; if you want tools for rendering boxes on images, see
|
|
397
|
-
|
|
395
|
+
visualization.visualization_utils.
|
|
398
396
|
|
|
399
397
|
The source image is:
|
|
400
398
|
|
|
@@ -896,7 +894,7 @@ def process_batch_results(options):
|
|
|
896
894
|
|
|
897
895
|
Ground truth, if available, must be in COCO Camera Traps format:
|
|
898
896
|
|
|
899
|
-
https://github.com/agentmorris/MegaDetector/blob/main/data_management/README.md#coco-camera-traps-format
|
|
897
|
+
https://github.com/agentmorris/MegaDetector/blob/main/megadetector/data_management/README.md#coco-camera-traps-format
|
|
900
898
|
|
|
901
899
|
Args:
|
|
902
900
|
options (PostProcessingOptions): everything we need to render a preview/analysis for
|
|
@@ -951,7 +949,7 @@ def process_batch_results(options):
|
|
|
951
949
|
# If the caller hasn't supplied results, load them
|
|
952
950
|
if options.api_detection_results is None:
|
|
953
951
|
detections_df, other_fields = load_api_results(
|
|
954
|
-
options.
|
|
952
|
+
options.md_results_file, force_forward_slashes=True,
|
|
955
953
|
filename_replacements=options.api_output_filename_replacements)
|
|
956
954
|
ppresults.api_detection_results = detections_df
|
|
957
955
|
ppresults.api_other_fields = other_fields
|
|
@@ -1026,11 +1024,11 @@ def process_batch_results(options):
|
|
|
1026
1024
|
job_name_string = options.job_name_string
|
|
1027
1025
|
else:
|
|
1028
1026
|
# This is rare; it only happens during debugging when the caller
|
|
1029
|
-
# is supplying already-loaded
|
|
1030
|
-
if options.
|
|
1027
|
+
# is supplying already-loaded MD results.
|
|
1028
|
+
if options.md_results_file is None:
|
|
1031
1029
|
job_name_string = 'unknown'
|
|
1032
1030
|
else:
|
|
1033
|
-
job_name_string = os.path.basename(options.
|
|
1031
|
+
job_name_string = os.path.basename(options.md_results_file)
|
|
1034
1032
|
|
|
1035
1033
|
if options.model_version_string is not None:
|
|
1036
1034
|
model_version_string = options.model_version_string
|
|
@@ -1800,13 +1798,13 @@ if False:
|
|
|
1800
1798
|
options = PostProcessingOptions()
|
|
1801
1799
|
options.image_base_dir = base_dir
|
|
1802
1800
|
options.output_dir = os.path.join(base_dir, 'preview')
|
|
1803
|
-
options.
|
|
1801
|
+
options.md_results_file = os.path.join(base_dir, 'results.json')
|
|
1804
1802
|
options.confidence_threshold = {'person':0.5,'animal':0.5,'vehicle':0.01}
|
|
1805
1803
|
options.include_almost_detections = True
|
|
1806
1804
|
options.almost_detection_confidence_threshold = 0.001
|
|
1807
1805
|
|
|
1808
1806
|
ppresults = process_batch_results(options)
|
|
1809
|
-
# from
|
|
1807
|
+
# from megadetector.utils.path_utils import open_file; open_file(ppresults.output_html_file)
|
|
1810
1808
|
|
|
1811
1809
|
|
|
1812
1810
|
#%% Command-line driver
|
|
@@ -1817,8 +1815,8 @@ def main():
|
|
|
1817
1815
|
|
|
1818
1816
|
parser = argparse.ArgumentParser()
|
|
1819
1817
|
parser.add_argument(
|
|
1820
|
-
'
|
|
1821
|
-
help='path to .json file
|
|
1818
|
+
'md_results_file',
|
|
1819
|
+
help='path to .json file containing MegaDetector results')
|
|
1822
1820
|
parser.add_argument(
|
|
1823
1821
|
'output_dir',
|
|
1824
1822
|
help='base directory for output')
|
|
@@ -20,12 +20,11 @@ from tqdm import tqdm
|
|
|
20
20
|
from collections import defaultdict
|
|
21
21
|
from functools import partial
|
|
22
22
|
|
|
23
|
-
from
|
|
24
|
-
from
|
|
25
|
-
from
|
|
26
|
-
from
|
|
27
|
-
|
|
28
|
-
import md_visualization.plot_utils as plot_utils
|
|
23
|
+
from megadetector.utils.path_utils import find_images
|
|
24
|
+
from megadetector.utils.path_utils import flatten_path
|
|
25
|
+
from megadetector.utils.write_html_image_list import write_html_image_list
|
|
26
|
+
from megadetector.visualization import visualization_utils as vis_utils
|
|
27
|
+
from megadetector.visualization import plot_utils
|
|
29
28
|
|
|
30
29
|
from multiprocessing.pool import ThreadPool
|
|
31
30
|
from multiprocessing.pool import Pool
|
|
@@ -4,7 +4,7 @@ find_repeat_detections.py
|
|
|
4
4
|
|
|
5
5
|
If you want to use this script, we recommend that you read the RDE user's guide:
|
|
6
6
|
|
|
7
|
-
https://github.com/agentmorris/MegaDetector/tree/
|
|
7
|
+
https://github.com/agentmorris/MegaDetector/tree/main/megadetector/postprocessing/repeat_detection_elimination
|
|
8
8
|
|
|
9
9
|
Really, don't try to run this script without reading the user's guide, you'll think
|
|
10
10
|
it's more magical than it is.
|
|
@@ -28,8 +28,8 @@ import argparse
|
|
|
28
28
|
import os
|
|
29
29
|
import sys
|
|
30
30
|
|
|
31
|
-
from
|
|
32
|
-
from
|
|
31
|
+
from megadetector.utils import ct_utils
|
|
32
|
+
from megadetector.postprocessing.repeat_detection_elimination import repeat_detections_core
|
|
33
33
|
|
|
34
34
|
|
|
35
35
|
#%% Interactive driver
|
|
@@ -7,7 +7,7 @@ to create a final filtered output file.
|
|
|
7
7
|
|
|
8
8
|
If you want to use this script, we recommend that you read the RDE user's guide:
|
|
9
9
|
|
|
10
|
-
https://github.com/agentmorris/MegaDetector/tree/
|
|
10
|
+
https://github.com/agentmorris/MegaDetector/tree/main/megadetector/postprocessing/repeat_detection_elimination
|
|
11
11
|
|
|
12
12
|
"""
|
|
13
13
|
|
|
@@ -15,7 +15,8 @@ https://github.com/agentmorris/MegaDetector/tree/master/api/batch_processing/pos
|
|
|
15
15
|
|
|
16
16
|
import argparse
|
|
17
17
|
import os
|
|
18
|
-
|
|
18
|
+
|
|
19
|
+
from megadetector.postprocessing.repeat_detection_elimination import repeat_detections_core
|
|
19
20
|
|
|
20
21
|
|
|
21
22
|
#%% Main function
|
|
@@ -7,7 +7,7 @@ Core utilities shared by find_repeat_detections and remove_repeat_detections.
|
|
|
7
7
|
Nothing in this file (in fact nothing in this subpackage) will make sense until you read
|
|
8
8
|
the RDE user's guide:
|
|
9
9
|
|
|
10
|
-
https://github.com/agentmorris/MegaDetector/tree/
|
|
10
|
+
https://github.com/agentmorris/MegaDetector/tree/main/megadetector/postprocessing/repeat_detection_elimination
|
|
11
11
|
|
|
12
12
|
"""
|
|
13
13
|
|
|
@@ -35,16 +35,16 @@ from multiprocessing.pool import ThreadPool
|
|
|
35
35
|
from multiprocessing.pool import Pool
|
|
36
36
|
from functools import partial
|
|
37
37
|
|
|
38
|
-
from
|
|
39
|
-
from
|
|
40
|
-
from
|
|
41
|
-
from
|
|
42
|
-
from
|
|
43
|
-
from
|
|
44
|
-
from
|
|
45
|
-
from
|
|
46
|
-
from
|
|
47
|
-
from
|
|
38
|
+
from megadetector.utils import path_utils
|
|
39
|
+
from megadetector.utils import ct_utils
|
|
40
|
+
from megadetector.postprocessing.load_api_results import load_api_results, write_api_results
|
|
41
|
+
from megadetector.postprocessing.postprocess_batch_results import is_sas_url
|
|
42
|
+
from megadetector.postprocessing.postprocess_batch_results import relative_sas_url
|
|
43
|
+
from megadetector.visualization.visualization_utils import open_image, render_detection_bounding_boxes
|
|
44
|
+
from megadetector.visualization import render_images_with_thumbnails
|
|
45
|
+
from megadetector.visualization import visualization_utils as vis_utils
|
|
46
|
+
from megadetector.utils.path_utils import flatten_path
|
|
47
|
+
from megadetector.utils.ct_utils import invert_dictionary
|
|
48
48
|
|
|
49
49
|
# "PIL cannot read EXIF metainfo for the images"
|
|
50
50
|
warnings.filterwarnings('ignore', '(Possibly )?corrupt EXIF data', UserWarning)
|
|
@@ -85,10 +85,9 @@ from multiprocessing.pool import ThreadPool
|
|
|
85
85
|
from functools import partial
|
|
86
86
|
from tqdm import tqdm
|
|
87
87
|
|
|
88
|
-
from
|
|
89
|
-
from detection.run_detector import get_typical_confidence_threshold_from_results
|
|
90
|
-
|
|
91
|
-
import md_visualization.visualization_utils as vis_utils
|
|
88
|
+
from megadetector.utils.ct_utils import args_to_object, is_float
|
|
89
|
+
from megadetector.detection.run_detector import get_typical_confidence_threshold_from_results
|
|
90
|
+
from megadetector.visualization import visualization_utils as vis_utils
|
|
92
91
|
|
|
93
92
|
friendly_folder_names = {'animal':'animals','person':'people','vehicle':'vehicles'}
|
|
94
93
|
|
|
@@ -62,8 +62,8 @@ import re
|
|
|
62
62
|
|
|
63
63
|
from tqdm import tqdm
|
|
64
64
|
|
|
65
|
-
from
|
|
66
|
-
from
|
|
65
|
+
from megadetector.utils.ct_utils import args_to_object, get_max_conf, invert_dictionary
|
|
66
|
+
from megadetector.utils.path_utils import top_level_folder
|
|
67
67
|
|
|
68
68
|
|
|
69
69
|
#%% Helper classes
|
|
@@ -15,8 +15,8 @@ import os
|
|
|
15
15
|
|
|
16
16
|
from tqdm import tqdm
|
|
17
17
|
|
|
18
|
-
from data_management.lila.lila_common import
|
|
19
|
-
read_wildlife_insights_taxonomy_mapping
|
|
18
|
+
from megadetector.data_management.lila.lila_common import \
|
|
19
|
+
read_lila_taxonomy_mapping, read_wildlife_insights_taxonomy_mapping
|
|
20
20
|
|
|
21
21
|
|
|
22
22
|
#%% Prevent execution during infrastructural imports
|
|
@@ -24,12 +24,8 @@ datasets_to_map = [
|
|
|
24
24
|
|
|
25
25
|
#%% Initialize taxonomic lookup
|
|
26
26
|
|
|
27
|
-
from taxonomy_mapping.species_lookup import
|
|
28
|
-
initialize_taxonomy_lookup,
|
|
29
|
-
get_preferred_taxonomic_match)
|
|
30
|
-
|
|
31
|
-
# from taxonomy_mapping.species_lookup import (
|
|
32
|
-
# get_taxonomic_info, print_taxonomy_matche)
|
|
27
|
+
from megadetector.taxonomy_mapping.species_lookup import \
|
|
28
|
+
initialize_taxonomy_lookup, get_preferred_taxonomic_match
|
|
33
29
|
|
|
34
30
|
initialize_taxonomy_lookup(force_init=False)
|
|
35
31
|
|
|
@@ -63,9 +63,8 @@ df = pd.read_csv(lila_taxonomy_file)
|
|
|
63
63
|
|
|
64
64
|
#%% Prepare taxonomy lookup
|
|
65
65
|
|
|
66
|
-
from taxonomy_mapping.species_lookup import
|
|
67
|
-
initialize_taxonomy_lookup,
|
|
68
|
-
get_preferred_taxonomic_match)
|
|
66
|
+
from megadetector.taxonomy_mapping.species_lookup import \
|
|
67
|
+
initialize_taxonomy_lookup, get_preferred_taxonomic_match
|
|
69
68
|
|
|
70
69
|
# from taxonomy_mapping.species_lookup import (
|
|
71
70
|
# get_taxonomic_info, print_taxonomy_matche)
|
|
@@ -390,7 +389,7 @@ remapped_queries = {'papio':'papio+baboon',
|
|
|
390
389
|
'mirafra':'genus+mirafra'}
|
|
391
390
|
|
|
392
391
|
import os
|
|
393
|
-
from taxonomy_mapping import retrieve_sample_image
|
|
392
|
+
from megadetector.taxonomy_mapping import retrieve_sample_image
|
|
394
393
|
|
|
395
394
|
scientific_name_to_paths = {}
|
|
396
395
|
image_base = os.path.join(preview_base,'images')
|
|
@@ -442,7 +441,7 @@ for i_row,row in df.iterrows():
|
|
|
442
441
|
|
|
443
442
|
#%% Rename .jpeg to .jpg
|
|
444
443
|
|
|
445
|
-
from
|
|
444
|
+
from megadetector.utils import path_utils
|
|
446
445
|
all_images = path_utils.recursive_file_list(image_base,False)
|
|
447
446
|
|
|
448
447
|
for fn in tqdm(all_images):
|
|
@@ -506,7 +505,7 @@ for images in scientific_name_to_preferred_images.values():
|
|
|
506
505
|
print('Using a total of {} images'.format(len(used_images)))
|
|
507
506
|
used_images_set = set(used_images)
|
|
508
507
|
|
|
509
|
-
from
|
|
508
|
+
from megadetector.utils import path_utils
|
|
510
509
|
all_images = path_utils.recursive_file_list(image_base,False)
|
|
511
510
|
|
|
512
511
|
unused_images = []
|
|
@@ -587,5 +586,5 @@ with open(html_output_file, 'w', encoding='utf-8') as f:
|
|
|
587
586
|
|
|
588
587
|
#%% Open HTML preview
|
|
589
588
|
|
|
590
|
-
from
|
|
589
|
+
from megadetector.utils.path_utils import open_file
|
|
591
590
|
open_file(html_output_file)
|
|
@@ -22,7 +22,7 @@ method = 'simple_image_download' # 'google_images_download'
|
|
|
22
22
|
|
|
23
23
|
if method == 'simple_image_download':
|
|
24
24
|
|
|
25
|
-
from taxonomy_mapping import simple_image_download
|
|
25
|
+
from megadetector.taxonomy_mapping import simple_image_download
|
|
26
26
|
google_image_downloader = simple_image_download.Downloader()
|
|
27
27
|
google_image_downloader.directory = output_folder
|
|
28
28
|
|
|
@@ -11,7 +11,7 @@ Confirm that all category names on LILA have mappings in the taxonomy file.
|
|
|
11
11
|
import json
|
|
12
12
|
import os
|
|
13
13
|
|
|
14
|
-
from data_management.lila.lila_common import read_lila_taxonomy_mapping
|
|
14
|
+
from megadetector.data_management.lila.lila_common import read_lila_taxonomy_mapping
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
#%% Prevent execution during infrastructural imports
|