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

Add converter from Pascal VOC to Weed COCO #101

Merged
merged 26 commits into from
Oct 8, 2020
Merged

Add converter from Pascal VOC to Weed COCO #101

merged 26 commits into from
Oct 8, 2020

Conversation

jnothman
Copy link
Contributor

@jnothman jnothman commented Oct 8, 2020

Fixes #33

Replaces #49

@jnothman
Copy link
Contributor Author

jnothman commented Oct 8, 2020

I'm currently getting a red mark here because license is required in each Image. I'd like to disable this requirement, and discuss how we want to represent image license, if we want to beyond collection membership, in a separate issue.

@jnothman
Copy link
Contributor Author

jnothman commented Oct 8, 2020

See #105, @hlydecker

Copy link
Contributor

@hlydecker hlydecker left a comment

Choose a reason for hiding this comment

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

I like the direction you are taking with the utils; it will be good to refactor as many functions as possible out of individual converters into this.

So far this looks good to me, @ElevnLi and I will expand on this with the RDS data.

@jnothman
Copy link
Contributor Author

jnothman commented Oct 8, 2020

Thanks for the review, just need to sync this with the current schema to make the ticks green...

@jnothman
Copy link
Contributor Author

jnothman commented Oct 8, 2020

This passes pytest locally... should be good to merge.

@codecov
Copy link

codecov bot commented Oct 8, 2020

Codecov Report

Merging #101 into master will increase coverage by 19.66%.
The diff coverage is 98.51%.

Impacted file tree graph

@@             Coverage Diff             @@
##           master     #101       +/-   ##
===========================================
+ Coverage   31.48%   51.15%   +19.66%     
===========================================
  Files           6        8        +2     
  Lines         343      477      +134     
===========================================
+ Hits          108      244      +136     
+ Misses        235      233        -2     
Flag Coverage Δ
#weedcoco 51.15% <98.51%> (+19.66%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
weedcoco/tests/importers/test_voc.py 97.77% <97.77%> (ø)
weedcoco/importers/voc.py 98.50% <98.50%> (ø)
weedcoco/utils.py 81.25% <100.00%> (+81.25%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3ae2860...7b3dc05. Read the comment docs.

@hlydecker hlydecker merged commit 4d57ff5 into master Oct 8, 2020
@jnothman
Copy link
Contributor Author

jnothman commented Oct 9, 2020

After updating weedcoco/schema/AgContext.yaml to support EPSG:3857, I could modify Guy's agcontext file and use this to load images into ES:

dir=/Volumes/research-data/PRJ-iweeds/data/raw/SOLES/narrabri/2019-winter/20190728
python -m weedcoco.importers.voc --voc-dir $dir/voc --image-dir $dir/img  --category-name-map $dir/category-name-map.yaml   --collection $dir/collection.yaml --agcontext $dir/agcontext.yaml -o /tmp/coco_from_voc-test.json --validate
cat /tmp/coco_from_voc-test.json | python weedcoco/draft\ export\ to\ elastic.py --thumbnail-dir artificial | curl -vv -X POST localhost:9200/_bulk  -H 'Content-Type: application/json' --data-binary @-

@jnothman jnothman mentioned this pull request Oct 12, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Converters for Pascal VOC datasets into Weed-COCO
2 participants