Skip to content

Commit

Permalink
SC_46 bump spatialdata
Browse files Browse the repository at this point in the history
  • Loading branch information
ArneDefauw committed Jan 23, 2025
1 parent 7a554b0 commit 55ed734
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions docs/tutorials/general/Harpy_feature_calculation.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -214,11 +214,11 @@
"#Hotfix: Due to an issue with passing z_axis to model.eval inside the Cellpose library, it appears to be ignored and is therefore automatically inferred incorrectly\n",
"#Temporary fix is to write to intermediate slot \"__image__\", with only one channel dimension.\n",
"img_layer = \"HumanLiverH35\"\n",
"sdata=harpy.im.add_image_layer( sdata, arr= sdata[ \"HumanLiverH35\" ].sel( c=\"R0 DAPI\" ).data[ None, ... ], output_layer=\"__image__\", overwrite=True )\n",
"sdata=harpy.im.add_image_layer( sdata, arr= sdata[ \"HumanLiverH35\" ].sel( c=\"R0 DAPI\" ).data[ None, ... ], output_layer=\"_image_\", overwrite=True )\n",
"\n",
"sdata = harpy.im.segment(\n",
" sdata,\n",
" img_layer=\"__image__\",\n",
" img_layer=\"_image_\",\n",
" chunks=1000,\n",
" depth=200,\n",
" model=cellpose_callable, # can be any callable. GPU will be used for segmentation if it could be found by torch (torch.cuda.is_available())\n",
Expand Down
4 changes: 2 additions & 2 deletions src/harpy/plot/_flowsom.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ def pixel_clusters(
target_coordinate_system=to_coordinate_system,
)
if se_crop is not None:
labels_layer_crop = f"__labels_{uuid.uuid4()}__"
labels_layer_crop = f"_labels_{uuid.uuid4()}_"
sdata[labels_layer_crop] = se_crop
se = se_crop
else:
Expand All @@ -100,7 +100,7 @@ def pixel_clusters(

cluster_ids = labels

intermediate_table_key = f"__value_clusters__{uuid.uuid4()}"
intermediate_table_key = f"_value_clusters_{uuid.uuid4()}"

# create a dummy anndata object, so we can plot cluster ID's spatially using spatialdata plot
obs = pd.DataFrame({_INSTANCE_KEY: cluster_ids}, index=cluster_ids)
Expand Down

0 comments on commit 55ed734

Please sign in to comment.