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

[DAR-3333][External] Import raster layer annotations even if classes are created or updated #918

Merged
merged 3 commits into from
Aug 27, 2024

Conversation

JBWilkie
Copy link
Collaborator

@JBWilkie JBWilkie commented Aug 27, 2024

Problem

When importing annotations, if any class needs to be created or assigned to the target dataset (not just masks), no raster layer annotations are actually imported

This is because if this happens, we create / update the classes as needed, then we re-fetch them here

The problem is when we re-fetch the classes, we only fetch classes assigned to the dataset with dataset.fetch_remote_classes()

Previously we were looking at team-wide classes with dataset.fetch_remote_classes(team_wide=True). It seems that the __raster_layer__ class is never assigned to any dataset. This is a problem because despite containing the actual annotation data, it's not assigned to the dataset so we skip importing it

Solution

Always return the __raster_layer__ class when fetching remote classes, because it's always available in every dataset

Changelog

Remove the need for a 2nd import to import mask annotations when classes are created or updated during import

Copy link

linear bot commented Aug 27, 2024

@JBWilkie JBWilkie merged commit fe582c8 into master Aug 27, 2024
24 checks passed
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

Successfully merging this pull request may close these issues.

2 participants