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

Images with the same tags multiple times #6

Open
davenquinn opened this issue Nov 27, 2018 · 7 comments
Open

Images with the same tags multiple times #6

davenquinn opened this issue Nov 27, 2018 · 7 comments

Comments

@davenquinn
Copy link
Contributor

davenquinn commented Nov 27, 2018

@cambro has found some double tagged images (same tags twice) on the validation side of the API. Thinking about how the frontend code works, it’s likely because, during the first annotation session on the frontend, new tags are not assigned a UUID yet, so they can be repeatedly saved with new UUIDs on the backend.

We could solve this two ways:

  1. Generate tag UUIDs on the frontend on initial creation. That way a tag persisted to the database multiple times would just overwrite previous values of the tag
  2. Have the /images/…/tags [POST] route return the entire collection of tags as a response (same signature as /images/…/tags [GET]). That way the frontend could replace the tag collection with the UUID-containing values from the backend

It seems that option 1 is a bit more flexible, the backend would just have to use the frontend-supplied UUID if set. In both options, the backend would have to deconflict changes by replacing UUID-owning tags with their updated values.

Another option that may obviate the need for all of this would be to do some post-processing of the tag store to only accept the most recent tagging session...or to only return tags from one session at a time for validation

@davenquinn
Copy link
Contributor Author

This whole tagging/validation split is a tricky workflow to support

@davenquinn
Copy link
Contributor Author

Mostly solved by af0dc3a, will leave this open for the moment.

@jczaplew
Copy link
Contributor

@davenquinn can you confirm that af0dc3a resolved this issue?

@davenquinn
Copy link
Contributor Author

Yep all fixed!

@jczaplew
Copy link
Contributor

Great! Thanks!

@cambro
Copy link
Contributor

cambro commented Dec 19, 2018

This is not fixed, or at least a related symptom appears not to be fixed.. Saving 2x for the same image during annotation, for example if you make a mistake, catch it, and correct it, will result in duplicated tags.

@cambro cambro reopened this Dec 19, 2018
@davenquinn
Copy link
Contributor Author

This is why we sync the uids between the backend and frontend, right? So I guess it is fixed on the frontend but not fully on the backend.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants