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

Delete observations with localizations #12

Closed
kevinsbarnard opened this issue Feb 9, 2023 · 3 comments
Closed

Delete observations with localizations #12

kevinsbarnard opened this issue Feb 9, 2023 · 3 comments
Assignees
Labels
enhancement New feature or request

Comments

@kevinsbarnard
Copy link
Collaborator

From @lonnylundsten 2/8/2023:

We have a problem in the way vars-gridview deals with these new localizations in vars. Over the last couple of days I have deleted hundreds of bad localizations from gridview, assuming that the annotations for those were also being deleted. However, when I open vars, I see that those annotations did not get deleted although their localizations did. My current solution will be to sort by existence of localization in vars (fg/s column) and delete the annotations that no longer have localizations. I guess we didn't really think about the behind the scenes behavior of gridview, but for this particular workflow, I think deletion of a localization in gridview must also delete the localizations in vars. Thoughts?

We need to add logic to vars-gridview in order to (optionally) delete an annotation when its localization is deleted. Due to the 1:N nature of observation:associations, there may be multiple bounding linked tied to a single observation. We need to be careful about how this is handled.

Proposal:

  1. User deletes a set of localizations
  2. For each localization, vars-gridview deletes the corresponding bounding box association in VARS
  3. For each parent observation of the bounding box association, vars-gridview checks if it is "dangling" (i.e., no more linked bounding box associations)
  4. Non-dangling observations (i.e., ones with more bounding boxes) are ignored
  5. The list of dangling observations will be presented to the user to confirm deletion; if accepted, those observations are deleted from VARS
@kevinsbarnard kevinsbarnard added the enhancement New feature or request label Feb 9, 2023
@kevinsbarnard kevinsbarnard self-assigned this Feb 9, 2023
@hohonuuli
Copy link
Member

Can we add an undo button too? In case users accidentally delete things they didn't want to?

@kevinsbarnard
Copy link
Collaborator Author

All things are possible in software... I'll add it to the list.

@kevinsbarnard kevinsbarnard mentioned this issue Feb 9, 2023
4 tasks
@kevinsbarnard
Copy link
Collaborator Author

This functionality is complete, minus the undo button. The undo button will be covered in #13

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

No branches or pull requests

2 participants