Skip to content

Releases: gustaveroussy/sopa

v2.1.3

29 Aug 08:42
Compare
Choose a tag to compare

[2.1.3] - 2025-08-29

Added

  • Add support for the new proseg version >=3.0.0
  • Added sopa-comseg Docker image for ComSeg support in nf-core/sopa
  • Can read CosMx polygons and cell labels (#285)

Fixed

  • Overwrite the scale parameter when running baysor and providing both config and scale parameters (#294)
  • Avoid losing prior cell 0 in prior assignment when unassigned_value != 0
  • Fixed stardist dependencies, as it still doesn't support numpy>=2.0.0
  • Fixed FOV shift in some CosMx versions (#286)

2.1.2

16 Aug 16:43
Compare
Choose a tag to compare

[2.1.2] - 2025-08-16

Added

  • Sopa is now also available on 🍏 nf-core (still in dev mode) - see this repo and the corresponding usage guide
  • Added a sopa:latest-tangram Docker image for cell-type annotation
  • Log a warning in case an annotation level group has multiple parents when running Tangram with multi-level.
  • Docs clarifications, e.g., how to use dataset_id for Visium HD data, and others improvements.
  • Store the cell to bins mapping in adata.obsm["bins_assignments"] during bins aggregation (#291)

Changed

  • Minor Snakemake files simplification (e.g., no need to provide the gene column name anymore)

Fixed

  • Preserve cell ids when converting to the explorer. Better interchangeability after filtering cells.
  • sopa --version faster and returns no warning (prevent it from importing sopa)
  • Preserve Xenium region_name and morphology_focus/mip files (via a symlink at the file level) when using sopa.io.explorer.write
  • Remove warning in sopa.io.explorer.write when mode="+it" and used before running Sopa (typically, when running the Snakemake or Nextflow pipeline)

v2.1.1

16 Jul 07:49
Compare
Choose a tag to compare

[2.1.1] - 2025-07-16

Added

  • Log a warning in sopa.io.visium_hd if the fullres image is too small (potentially a user error)
  • Added a allow_holes argument to sopa.segmentation.tissue to decide whether to keep holes or not
  • correction argument in sopa.spatial.mean_distance to account for the bias related to group proportions (experimental)
  • The Docker CI now also pushes the images with the latest tag

Changed

  • CosMx reader: use flip_image=False by default (#231)

Fixed

  • _smoothen_cell returns an empty polygon if the cell can't be smoothened (#279)
  • Remove NaN genes before transcript-based segmentation (#283)
  • Broken link in the docs @ChristopherBottomsOMRF (#284)
  • Added again the command ps to all Docker images for Nextflow

v2.1.0

27 Jun 09:36
Compare
Choose a tag to compare

[2.1.0] - 2025-06-27

Added

  • Add no_overlap argument in sopa.aggregate to avoid cells from overlapping when aggregating the channels/bins
  • Map each VisiumHD bin to one unique cell using PCA proximity (see no_overlap argument)
  • Better documentation for sopa.io.visium_hd and a warning if the full res image is not loaded (#254)
  • Support CONCH for H&E patches inference.
  • Support cellpose>=4.0.0 @lguerard (#252, #264)

Changed

  • Use the global coordinate system by default in the remaining readers that were still using the pixels coordinate system
  • Default to prior_shapes_key: auto in all Snakemake config - it will automatically find the right key based on the technology
  • To use cellpose with GPU, gpu=True must be passed directly as an arg/kwarg instead of inside cellpose_eval_kwargs, or via --gpu for the CLI, or via adding gpu: true to the Snakemake config (under the cellpose section).
  • (Internal) use disk from skimage for opening/closing in sopa.segmentation.tissue
  • (Internal) refactor Patches2D to make it faster when the ROI is complex with 100,000+ shapes

Fixed

  • Fixed report (transcript section) when adata.X is not sparse + add spatial count distribution
  • Support x/y_global_mm for transcripts in the CosMx reader (#274)

Removed

  • Removed the open-cv dependency (#239)
  • Removed all deprecated functions that were announced to be removed in this version

v2.0.7

19 May 07:56
Compare
Choose a tag to compare

[2.0.7] - 2025-05-19

Added

  • sopa.patches.compute_embeddings returns key_added for convenience
  • Added sopa.io.bioio generic reader

Fixed

  • Pin cellpose<4.0.0 (#252)
  • Using bounding boxes center instead of the shape centroids for patches location in adata.obsm after using sopa.patches.compute_embeddings
  • Force sopa version in Docker images CI @Clemsazert (#251)

Fixed

v2.0.6

24 Apr 09:33
Compare
Choose a tag to compare

[2.0.6] - 2025-04-24

Added

  • New Resolve Bioscience reader sopa.io.molecular_cartography (#240)
  • Adding roi_key argument in sopa.patches.compute_embeddings to filter the patches by any shapes element (not just the segmented tissue). For instance, keep only the patches behind the cells.
  • Docker images auto build on tag release (#242) @Clemsazert

Fixed

  • When installing the stardist extra, force numpy<2.0.0 (#245)

v2.0.4

08 Apr 17:04
Compare
Choose a tag to compare

[2.0.4] - 2025-04-08

Added

  • Add prior_shapes_key="auto" to automatically detect the prior proprietary segmentation when making transcript patches
  • Direct stardist CLI/snakemake support (not just via generic-staining)
  • Added a snakemake config for Visium HD data (with stardist segmentation)
  • Proseg support for Snakemake
  • CLI command sopa --version to show the version of Sopa

Fixed

  • Fix CosMX reader issues related to the channel names, FOV names, and image flipping (#180, #227, #231)
  • Fix expand_radius_ratio=None usage for bins aggregation (#226)
  • Stardist: use clip=True when normalizing images to avoid -1e20 values

Changed

  • Snakemake pipeline refactoring to better support the increasing number of segmentation tools
  • Tangram now has to be installed via pip install tangram-sc rather than via the sopa extra

v2.0.3

13 Mar 10:21
Compare
Choose a tag to compare

[2.0.3] - 2025-03-13

Added

  • Experimental support of proseg @lguerard (#223) - tutorial coming soon
  • Use symlink to Xenium output morphology/transcripts files to avoid duplicating data (#221)
  • Run module load baysor in Snakemake pipeline if the module is available.

Fixed

  • Use sdata.path.resolve() to compute the cache dir (more robust to execution path change)

Changed

  • Using density_prior = "uniform" by default for Tangram (#174)
  • spatialdata_plot is now a default dependency of Sopa
  • Use prob_thresh=0.2 and nms_thresh=0.6 by default in stardist
  • During segmentation, pixels outside of the ROI / tissue use the mean channels value instead of 0 (#222)

v2.0.2

21 Feb 09:18
Compare
Choose a tag to compare

[2.0.2] - 2025-02-21

Added

  • Added H-optimus-0 model for H&E patches embeddings @stergioc (#208)
  • Can provide qv_threshold argument to the Xenium reader to filter low-quality transcripts @callum-jpg (#210)

Changed

  • Storing patches embeddings as an AnnData object instead of images (#212) (see updated tuto)

Fixed

  • Right sorting scales for WSI reader with openslide backend @stergioc (#209)
  • When a polygon cannot be simplified (for the Xenium Explorer), convert it to a circle (#206)
  • sopa explorer write: use correct default argument for table_key in the CLI (#211)
  • Fix Baysor usage on Windows (#185)
  • Fix tight patches returning a different number of patches (#214)

v2.0.1

10 Feb 17:22
Compare
Choose a tag to compare

[2.0.1] - 2025-02-10

Fixed

  • Safer check dataframe series is of integer dtype (#179)
  • Ensure feature_key is converted correctly to a string (#185)
  • Fixed the WSI readers @stergioc (#192)
  • Fixed points_key usage in sopa.aggregate (#194)

Added

  • Aggregation and segmentation now exclude non-interesting gene names (e.g., "blank", "unassigned", ...) (#144)
  • Can filter low-quality transcript for transcript-based segmentation (#79)
  • Possibility to choose the table name for the report (#183)
  • Possibility to choose the table name for sopa.io.explorer.write (#183)
  • Can set all spatialdata_io.xenium arguments in sopa.io.xenium
  • CLI for stardist @jeffquinn-msk (#189)
  • Baysor logs if running on one patch, and return the right error code in CLI @jeffquinn-msk (#199)
  • Baysor parallelization per patch @Marius1311 (#203)

Changed

  • sopa.io.write_report is copying the adata to avoid modifying it (#196)