Skip to content

Conversation

@DanielaSchacherer
Copy link
Contributor

As discussed, I added the BMDeep tutorial. Happy for feedback! :)

@review-notebook-app
Copy link

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@DanielaSchacherer
Copy link
Contributor Author

@fedorov did we already talk about this? If not, maybe we should briefly in the Slim meeting later today!

@fedorov fedorov requested a review from Copilot January 22, 2026 14:12
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot wasn't able to review any files in this pull request.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@fedorov
Copy link
Member

fedorov commented Jan 22, 2026

I admit I lost track of this PR...

@DanielaSchacherer
Copy link
Contributor Author

no problem, me too :D

@fedorov
Copy link
Member

fedorov commented Feb 2, 2026

@DanielaSchacherer I pushed some minor changes, and also left some suggestion in the comments here: https://colab.research.google.com/drive/1kD_mEbfi1ozhyyS0WK9zl3vyKYMJJJjA?usp=sharing

@DanielaSchacherer
Copy link
Contributor Author

I took the feedback in and answered to your comments in the notebook linked above. I already changed the code to use ann_index, so let's not merge yet, but let me test as soon as ann_index is out :)

@DanielaSchacherer
Copy link
Contributor Author

@fedorov do you have any additional feedback?

@fedorov
Copy link
Member

fedorov commented Feb 9, 2026

You rely on "monolayer" in SeriesDescription in one of the queries, which is not a good pattern.

Why not use ann_group_index and search by Selected region?

Search by unstructured data is not desirable, especially when the query can be resolved using structured data.

client.fetch_index("ann_group_index")

# Select all annotation groups from ANN series whose SeriesDescription
# mentions "monolayer" in the bonemarrowwsi_pediatricleukemia collection
monolayer_ann_groups = client.sql_query("""
    SELECT
        ag.SeriesInstanceUID,
        ag.AnnotationGroupNumber,
        ag.AnnotationGroupUID,
        ag.AnnotationGroupLabel,
        ag.NumberOfAnnotations,
        ag.GraphicType,
        ag.AnnotationPropertyCategory_CodeMeaning,
        ag.AnnotationPropertyType_CodeMeaning,
        ai.referenced_SeriesInstanceUID
    FROM ann_group_index ag
    JOIN ann_index ai
      ON ag.SeriesInstanceUID = ai.SeriesInstanceUID
    JOIN index i
      ON ag.SeriesInstanceUID = i.SeriesInstanceUID
    WHERE i.collection_id = 'bonemarrowwsi_pediatricleukemia'
      AND ag.AnnotationPropertyType_CodeMeaning = 'Selected region'
    ORDER BY ag.SeriesInstanceUID, ag.AnnotationGroupNumber
""")

print(f"Found {len(monolayer_ann_groups)} annotation groups "
      f"across {monolayer_ann_groups['SeriesInstanceUID'].nunique()} ANN series")
display(monolayer_ann_groups)

@fedorov
Copy link
Member

fedorov commented Feb 9, 2026

Also note that idc-index has been updated, and should allow fetching ann_group_index.

@fedorov
Copy link
Member

fedorov commented Feb 10, 2026

I think similar comment applies further in the notebook where you deal with unlabeled cells.

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