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

Dev #60

Merged
merged 15 commits into from
Apr 26, 2024
Merged

Dev #60

Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,12 @@
## [1.0.11] - 2024-xx-xx
## [1.x.x] - xxxx-xx-xx

## [1.0.11] - 2024-04-26

### Added
- Can overlay a custom segmentation (merge boundaries)
- Xenium Explorer selection(s) can be added as shapes in a SpatialData object
- Optionnal OpenSlide backend for WSI data
- New `sopa.io.aicsimageio` reader for special formats (#58)

### Changed
- Rename `Aggregator.update_table` to `Aggregator.compute_table`
Expand Down
12 changes: 0 additions & 12 deletions docs/api/_sdata.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,25 +2,13 @@
These are convenient tools that operates on `SpatialData` objects

::: sopa._sdata.get_boundaries
options:
show_root_heading: true

::: sopa._sdata.get_intrinsic_cs
options:
show_root_heading: true

::: sopa._sdata.to_intrinsic
options:
show_root_heading: true

::: sopa._sdata.get_intensities
options:
show_root_heading: true

::: sopa._sdata.iter_scales
options:
show_root_heading: true

::: sopa._sdata.get_spatial_image
options:
show_root_heading: true
5 changes: 5 additions & 0 deletions docs/api/annotation.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
::: sopa.annotation.tangram_annotate

::: sopa.annotation.higher_z_score

::: sopa.annotation.preprocess_fluo
7 changes: 0 additions & 7 deletions docs/api/annotation/fluorescence.md

This file was deleted.

3 changes: 0 additions & 3 deletions docs/api/annotation/tangram.md

This file was deleted.

2 changes: 0 additions & 2 deletions docs/api/embedding.md
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
::: sopa.embedding.embed_wsi_patches
options:
show_root_heading: true
47 changes: 0 additions & 47 deletions docs/api/io.explorer.md

This file was deleted.

46 changes: 26 additions & 20 deletions docs/api/io.md
Original file line number Diff line number Diff line change
@@ -1,45 +1,51 @@
# sopa.io

!!! notes
Due to many updates in the data format provided by the different companies, you might have issues loading your data. In this case, consider [opening an issue](https://github.com/gustaveroussy/sopa/issues) detailing the version of the machine you used and the error log, as well as an example of file names that you are trying to read.

!!! notes "Related to `spatialdata-io`"
A library called [`spatialdata-io`](https://spatialdata.scverse.org/projects/io/en/latest/) already contains a lot of readers. Here, we updated some readers already existing in `spatialdata-io`, and added a few others. In the future, we will completely rely on `spatialdata-io`.

## Readers

::: sopa.io.xenium
options:
show_root_heading: true

::: sopa.io.merscope
options:
show_root_heading: true

::: sopa.io.cosmx
options:
show_root_heading: true

::: sopa.io.macsima
options:
show_root_heading: true

::: sopa.io.phenocycler
options:
show_root_heading: true

::: sopa.io.hyperion
options:
show_root_heading: true

::: sopa.io.aicsimageio

::: sopa.io.ome_tif
options:
show_root_heading: true

::: sopa.io.wsi
options:
show_root_heading: true

::: sopa.io.uniform
options:
show_root_heading: true

::: sopa.io.blobs
options:
show_root_heading: true

## Xenium Explorer

::: sopa.io.write

::: sopa.io.align

::: sopa.io.add_explorer_selection

::: sopa.io.int_cell_id

::: sopa.io.str_cell_id

::: sopa.io.write_image

::: sopa.io.save_column_csv

## Report

::: sopa.io.write_report
59 changes: 0 additions & 59 deletions docs/api/io.report.md

This file was deleted.

12 changes: 0 additions & 12 deletions docs/api/segmentation/aggregate.md
Original file line number Diff line number Diff line change
@@ -1,23 +1,11 @@
::: sopa.segmentation.aggregate.overlay_segmentation
options:
show_root_heading: true

::: sopa.segmentation.aggregate.average_channels
options:
show_root_heading: true

::: sopa.segmentation.aggregate._average_channels_aligned
options:
show_root_heading: true

::: sopa.segmentation.aggregate.count_transcripts
options:
show_root_heading: true

::: sopa.segmentation.aggregate._count_transcripts_aligned
options:
show_root_heading: true

::: sopa.segmentation.aggregate.Aggregator
options:
show_root_heading: true
2 changes: 0 additions & 2 deletions docs/api/segmentation/baysor.md
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
::: sopa.segmentation.baysor.resolve.resolve
options:
show_root_heading: true
2 changes: 0 additions & 2 deletions docs/api/segmentation/methods.md
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
::: sopa.segmentation.methods.cellpose_patch
options:
show_root_heading: true
2 changes: 0 additions & 2 deletions docs/api/segmentation/patching.md
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
::: sopa.segmentation.patching.Patches2D
options:
show_root_heading: true
6 changes: 0 additions & 6 deletions docs/api/segmentation/shapes.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,5 @@
::: sopa.segmentation.shapes.solve_conflicts
options:
show_root_heading: true

::: sopa.segmentation.shapes.geometrize
options:
show_root_heading: true

::: sopa.segmentation.shapes.rasterize
options:
show_root_heading: true
2 changes: 0 additions & 2 deletions docs/api/segmentation/stainings.md
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
::: sopa.segmentation.stainings.StainingSegmentation
options:
show_root_heading: true
2 changes: 0 additions & 2 deletions docs/api/segmentation/tissue.md
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
::: sopa.segmentation.tissue.hsv_otsu
options:
show_root_heading: true
14 changes: 0 additions & 14 deletions docs/api/spatial.md
Original file line number Diff line number Diff line change
@@ -1,27 +1,13 @@
::: sopa.spatial.sjoin
options:
show_root_heading: true

::: sopa.spatial.mean_distance
options:
show_root_heading: true

::: sopa.spatial.geometrize_niches
options:
show_root_heading: true

::: sopa.spatial.niches_geometry_stats
options:
show_root_heading: true

::: sopa.spatial.cells_to_groups
options:
show_root_heading: true

::: sopa.spatial.spatial_neighbors
options:
show_root_heading: true

::: sopa.spatial.prepare_network
options:
show_root_heading: true
6 changes: 0 additions & 6 deletions docs/api/utils/image.md
Original file line number Diff line number Diff line change
@@ -1,11 +1,5 @@
::: sopa.utils.image.scale_dtype
options:
show_root_heading: true

::: sopa.utils.image.resize
options:
show_root_heading: true

::: sopa.utils.image.resize_numpy
options:
show_root_heading: true
2 changes: 0 additions & 2 deletions docs/api/utils/polygon_crop.md
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
::: sopa.utils.polygon_crop.polygon_selection
options:
show_root_heading: true
7 changes: 3 additions & 4 deletions docs/tutorials/align.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,10 @@ Convert your image with QuPath as written in this [10x genomics webpage](https:/

If you are not familiar with QuPath, you can also use our API to write the image:
```python
from sopa import io
from sopa.io.explorer import write_image
import sopa.io

image = io.ome_tif("path/to/your/image.tif") # or use a different reader
write_image("where/to/save/image.ome.tif", image, is_dir=False)
image = sopa.io.ome_tif("path/to/your/image.tif") # or use a different reader
sopa.io.write_image("where/to/save/image.ome.tif", image, is_dir=False)
```

!!! note "Xenium users"
Expand Down
13 changes: 7 additions & 6 deletions mkdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,7 @@ nav:
- sopa.segmentation.tissue: api/segmentation/tissue.md
- sopa.segmentation.baysor: api/segmentation/baysor.md
- sopa.io: api/io.md
- sopa.io.explorer: api/io.explorer.md
- sopa.io.report: api/io.report.md
- sopa.annotation:
- sopa.annotation.tangram: api/annotation/tangram.md
- sopa.annotation.fluorescence: api/annotation/fluorescence.md
- sopa.annotation: api/annotation.md
- sopa.utils:
- sopa.utils.image: api/utils/image.md
- sopa.utils.polygon_crop: api/utils/polygon_crop.md
Expand All @@ -45,7 +41,12 @@ nav:
- Cite us: cite_us.md
plugins:
- search
- mkdocstrings
- mkdocstrings:
handlers:
python:
options:
show_root_heading: true
heading_level: 3
- mkdocs-jupyter:
include_source: True
markdown_extensions:
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "sopa"
version = "1.0.10"
version = "1.0.11"
description = "Spatial-omics pipeline and analysis"
documentation = "https://gustaveroussy.github.io/sopa"
homepage = "https://gustaveroussy.github.io/sopa"
Expand Down
1 change: 1 addition & 0 deletions sopa/annotation/__init__.py
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
from .fluorescence import preprocess_fluo, higher_z_score
from .tangram import tangram_annotate
Loading
Loading