Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implementation of Stanford Cars prototype dataset #5442

Merged
merged 71 commits into from
Mar 10, 2022

Conversation

abhi-glitchhg
Copy link
Contributor

@abhi-glitchhg abhi-glitchhg commented Feb 18, 2022

stanford cars prototype dataset #5336

@facebook-github-bot
Copy link

facebook-github-bot commented Feb 18, 2022

💊 CI failures summary and remediations

As of commit 801e9b0 (more details on the Dr. CI page):


💚 💚 Looks good so far! There are no failures yet. 💚 💚


This comment was automatically generated by Dr. CI (expand for details).

Please report bugs/suggestions to the (internal) Dr. CI Users group.

Click here to manually regenerate this comment.

@abhi-glitchhg abhi-glitchhg marked this pull request as draft February 18, 2022 17:56
@abhi-glitchhg abhi-glitchhg changed the title [WIP] Stanford Cars prototype dataset [WIP] Implementation of Stanford Cars prototype dataset Feb 19, 2022
@abhi-glitchhg
Copy link
Contributor Author

abhi-glitchhg commented Feb 19, 2022

I have got a problem and I am not able to fix it.
the _make_datapipe method recieves a list of IterPipe objects. There will be two objects becuase resources method return a list with two HttpResource objects.

So as per my understanding first object will be related to images(TarArchiveReaderIterDataPipe object) and second object will be related to labels and bounding boxes(FileOpenerIterDataPipe object).
And this is correct ;

images dp: <torchdata.datapipes.iter.util.tararchivereader.TarArchiveReaderIterDataPipe object at 0x7f43f5ed4910> targets dp: <torch.utils.data.datapipes.iter.fileopener.FileOpenerIterDataPipe object at 0x7f43f5ed4340>

but sometimes both the dps are related to the labels and bounding boxes;

images dp: <torch.utils.data.datapipes.iter.fileopener.FileOpenerIterDataPipe object at 0x7fd7ef58edc0> targets dp: <torch.utils.data.datapipes.iter.fileopener.FileOpenerIterDataPipe object at 0x7fd7ef5a7160>

I do not understand why this is happening?
Can anyone help me out?
Thanks

cc @pmeier

Copy link
Contributor

@pmeier pmeier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @abhi-glitchhg for reporting this. This is a bug in our resource loading. I've send a patch in #5447 that should fix this behavior. After that is merged, you can update your branch and the issue should be gone.

I had an superficial look and so far this looks really good! I'll do another round after you mark the PR as ready for review.

@pmeier pmeier linked an issue Feb 23, 2022 that may be closed by this pull request
@abhi-glitchhg
Copy link
Contributor Author

Sorry for the delay! I will try to finish this by the weekend!

@abhi-glitchhg abhi-glitchhg marked this pull request as draft March 7, 2022 09:04
@abhi-glitchhg abhi-glitchhg marked this pull request as ready for review March 8, 2022 17:13
Copy link
Contributor

@pmeier pmeier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @abhi-glitchhg, we are almost done! Just a few minor comments including #5442 (comment) from a previous review left. After that we are good to merge!

test/builtin_dataset_mocks.py Outdated Show resolved Hide resolved
test/builtin_dataset_mocks.py Outdated Show resolved Hide resolved
test/builtin_dataset_mocks.py Outdated Show resolved Hide resolved
Copy link
Contributor

@pmeier pmeier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome, thanks a lot for the patience @abhi-glitchhg!

@pmeier pmeier requested a review from NicolasHug March 9, 2022 13:16
@pmeier
Copy link
Contributor

pmeier commented Mar 9, 2022

Hey @abhi-glitchhg, we appreciate your responsiveness, but you don't need to update the branch for every new commit on the main branch. We will do that before we merge. Otherwise, we would be wasting a lot of CI resources for very little gain.

One exception is if GitHub auto-detects some conflicts. In that case, feel free to address them before the final approval.

Copy link
Member

@NicolasHug NicolasHug left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Stamping, thanks @abhi-glitchhg

@pmeier pmeier merged commit a8bde78 into pytorch:main Mar 10, 2022
facebook-github-bot pushed a commit that referenced this pull request Mar 15, 2022
Summary:
* basic stanford cars structure added.

* added class in the init.

* how to decode the images

* fix typo in init

* works partially

* formatting

* formatting

* formatting

* formatting

* formatting

* minor changes

* minor changes

* issue resolved

* both datapipes are in sync

* checksum dict keys changed

* formatting

* "ufmt formatting"

* "ufmt formatting"

* formatting

* minor change

* minor change

* test added

* lint (end of line issue)

* lint (end of line issue)

* minor changes

* mock dataset formatting

* minor changes

* hopefully final

* formatting

* prototype test

* prototype test

* prototype test

* prototype test

* prototype test

* prototype test

* prototype test

* prototype test

* Update builtin_dataset_mocks.py

* Update stanford_cars.py

* Update torchvision/prototype/datasets/_builtin/stanford_cars.py

* Update torchvision/prototype/datasets/_builtin/stanford_cars.py

* Update torchvision/prototype/datasets/_builtin/stanford_cars.py

* Update torchvision/prototype/datasets/_builtin/stanford_cars.py

* formatting and cleaning

* formatting and cleaning

* Update torchvision/prototype/datasets/_builtin/stanford_cars.py

* generate catefories script

* generate categories script added

* sigh

* sigh

* sigh

* minor changes

* linting

Reviewed By: vmoens

Differential Revision: D34879003

fbshipit-source-id: d9ffca1e9c2f5758dc0f4571f4e915fe45cb4b68

Co-authored-by: Philip Meier <github.pmeier@posteo.de>
Co-authored-by: Philip Meier <github.pmeier@posteo.de>
Co-authored-by: Philip Meier <github.pmeier@posteo.de>
Co-authored-by: Philip Meier <github.pmeier@posteo.de>
Co-authored-by: Philip Meier <github.pmeier@posteo.de>
Co-authored-by: Philip Meier <github.pmeier@posteo.de>
Co-authored-by: Nicolas Hug <contact@nicolas-hug.com>
@abhi-glitchhg abhi-glitchhg deleted the stanfordcars branch August 8, 2022 18:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

StanfordCars
4 participants