Skip to content

Segmentation mask input with morphology_focus names that don't match spatialdata-io expected names #2

@spatts14

Description

@spatts14

I have this issue: scverse/spatialdata-io#325 (comment) and someone suggested scverse/spatialdata-io#312 would have addressed it but it isnt working for me.

Until spatialdata-io fix the code, we need a work around. I think that would be renaming all the files in the output manually and then creating a new morphology.ome.tif file. I tried renaming the files from the names that come off the machine to the ones spaitaldata-io expects, however I'm still getting an error. It seems that there is some link between the names in the morphology_focus dir and morphology.ome.tif file.

I think the temp work around could be

  1. Rename the files in morphology_focus dir
  2. Create a new morphology.ome.tif and overwrite the old one using the renamed files in morphology_focus dir

This needs to be done for every ROI/sample (i.e every folder because each sample has its own folder with the layout below)

.
├── analysis
│   ├── clustering
│   ├── diffexp
│   ├── pca
│   └── umap
├── analysis_summary.html
├── analysis.zarr.zip
├── aux_outputs
│   ├── background_qc_images
│   ├── morphology_focus_qc_masks
│   ├── morphology_fov_locations.json
│   ├── overview_scan_fov_locations.json
│   ├── overview_scan.png
│   └── per_cycle_channel_images
├── cell_boundaries.csv.gz
├── cell_boundaries.parquet
├── cell_feature_matrix
│   ├── barcodes.tsv.gz
│   ├── features.tsv.gz
│   └── matrix.mtx.gz
├── cell_feature_matrix.h5
├── cell_feature_matrix.zarr.zip
├── cells.csv.gz
├── cells.parquet
├── cells.zarr.zip
├── experiment.xenium
├── gene_panel.json
├── metrics_summary.csv
├── morphology_focus
│   ├── ch0000_dapi.ome.tif
│   ├── ch0001_atp1a1_cd45_e-cadherin.ome.tif
│   ├── ch0002_18s.ome.tif
│   └── ch0003_alphasma_vimentin.ome.tif
├── morphology.ome.tif
├── nucleus_boundaries.csv.gz
├── nucleus_boundaries.parquet
├── transcripts.parquet
└── transcripts.zarr.zip

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions