scverse / scverse/spatialdata-io
visium_hd reader: load_segmentations_only = False still loads segmentation results
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 103
- Forks
- 65
- Avg merge
- 1h 8m
- Merged PRs (30d)
- 3
Description
Hi, I am on spatialdata-io 0.5.1 and I noticed that for the visium_hd() reader, the load_segmentations_only=False does not strictly replicate legacy behavior.
The docstring states:
load_segmentations_only
If `True`, only the segmented cell boundaries and their associated counts will be loaded. All binned data
will be skipped. If `False`, only the binned data will be loaded (which is consistent with legacy behavior).
If `None` (default), it will be equivalent to `False`, but a deprecation warning will be raised to inform users that
in future releases the default value will be changed to `True`. To avoid the warning, explicitly set this parameter to
`False` or `True`.
However, regardles of whether load_segmentations_only is True or False, segmentation results are loaded if present. load_segmentations_only currently only seems to have an effect on whether the binned data is loaded or not.
I think the desired behavior would indeed be that the users has a choice of whether to load the binned data, the segmentation results or both. Note that even if the reader behaved as stated in the docstring, this would then not give you the option of reading in both.
Thanks!
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start at the visium_hd() reader and trace how load_segmentations_only controls loading of segmentation results and binned data. Compare the implementation with the documented behavior, then define how the reader should represent loading binned data, segmentations, or both and verify each supported option.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100