Jaap/fix coc oloader max individuals - #3435
Draft
deruyter92 wants to merge 3 commits into
Draft
Conversation
…ping of individuals from train and test json
2 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #3432.
COCOLoader.get_dataset_parametersderivedbodyparts/individualsfromtrain.jsonand ignoredmodel_cfg.metadata, whileDLCLoadertreated the config as authoritative.max_individualshad no effect on COCO projects, and training/evaluation could crash deep insidepad_to_lengthwhenever an image had more individuals than the busiest training image.model_cfg.metadatais now authoritative forbodyparts/individuals, matchingDLCLoader.COCOLoadernow validatestrain.json/test.jsonagainstmodel_cfg.metadataat construction time, raisingValueErrorif an image has more individuals than the model supports, or if the annotated bodyparts don't match the configured ones.get_project_parametersnow optionally takestest_jsonand suggestsmax_individualsacross both splits, instead of onlytrain.json. docssting is updated to describe the non-authorative bootstrapping role of the method.tests/pose_estimation_pytorch/data/test_cocoloader.pycovering:get_dataset_parametersusesmodel_cfgcapacity (not the JSON) when it covers both splitsValueErrorwhen an image (train or test) exceeds the configured capacityValueErroron bodypart mismatchtest.jsonget_project_parameterssuggestions cover both train and test JSON, raise on an empty dataset, and warn on multi-category JSON (both splits)