scverse / scverse/spatialdata-plot

3D visualize

Ouverte
#385 3 commentaires 0 réactions 0 personnes assignées Voir sur GitHub

Personne n'a encore pris cette issue.

Langage dominant
Python
Étoiles
86
Forks
21
Merge moyen
14 h 50 min
PR mergées (30 j)
3

Description

Hi developer.

Thanks alot for the useful tools and sorry for keep bothering.

I need a 3D visualiza on my xenium dataset. Now I can correctly load my xenium data and check the transcripts point on 2D shape.
I'm wondering if there is any plan to add the 3D visualize feature.

I also try to subset my sdata["transcripts"] based on the z value. however, after subset, I try to construct the sdata, it's not working. and showed error code. ValueError('Unable to coerce to Series, length must be 11: given 2')

Please also let me know if you have better recommendation on 3D visualization of xenium data.


ValueError Traceback (most recent call last)
d:\Yifan_Wang\Software\envs\SP\lib\site-packages\dask\dataframe\utils.py in ?(funcname, udf)
214 )
215 msg = msg.format(f" in {funcname}" if funcname else "", repr(e), tb)
--> 216 raise ValueError(msg) from e

d:\Yifan_Wang\Software\envs\SP\lib\site-packages\dask\dataframe\core.py in ?(op, meta, out, transform_divisions, *args, **kwargs)
6624 for d in dasks
6625 ]
-> 6626 with raise_on_meta_error(funcname(op)):
6627 meta = partial_by_order(*parts, function=op, other=other)

d:\Yifan_Wang\Software\envs\SP\lib\site-packages\dask\utils.py in ?(*args, **kwargs)
1474 for i, arg in other:
1475 args2.insert(i, arg)
-> 1476 return function(*args2, **kwargs)

d:\Yifan_Wang\Software\envs\SP\lib\site-packages\pandas\core\ops\common.py in ?(self, other)
74 other = item_from_zerodim(other)
75
---> 76 return method(self, other)

d:\Yifan_Wang\Software\envs\SP\lib\site-packages\pandas\core\arraylike.py in ?(self, other)
80 @unpack_zerodim_and_defer("ror")
81 def ror(self, other):
---> 82 return self.logical_method(other, roperator.ror)

d:\Yifan_Wang\Software\envs\SP\lib\site-packages\pandas\core\frame.py in ?(self, other, op)
7908 other = ops.maybe_prepare_scalar_for_op(other, (self.shape[axis],))
7909
-> 7910 self, other = self._align_for_op(other, axis, flex=True, level=None)
7911

d:\Yifan_Wang\Software\envs\SP\lib\site-packages\pandas\core\frame.py in ?(self, other, axis, flex, level)
8185 )
8186 # GH#17901
-> 8187 right = to_series(right)
8188

d:\Yifan_Wang\Software\envs\SP\lib\site-packages\pandas\core\frame.py in ?(right)
8131 else:
8132 if len(left.columns) != len(right):
-> 8133 raise ValueError(
8134 msg.format(req_len=len(left.columns), given_len=len(right))

ValueError: Unable to coerce to Series, length must be 11: given 2

The above exception was the direct cause of the following exception:

ValueError Traceback (most recent call last)
Cell In[46], line 1
----> 1 merged_dict_crop = my_images | my_labels | filtered_data | my_shapes | my_tables
2 print(merged_dict.keys())

File d:\Yifan_Wang\Software\envs\SP\lib\site-packages\dask\dataframe\core.py:2124, in _Frame._get_binary_operator..(self, other)
2121 @classmethod
2122 def _get_binary_operator(cls, op, inv=False):
2123 if inv:
-> 2124 return lambda self, other: elemwise(op, other, self)
2125 else:
2126 return lambda self, other: elemwise(op, self, other)

File d:\Yifan_Wang\Software\envs\SP\lib\site-packages\dask\dataframe\core.py:6626, in elemwise(op, meta, out, transform_divisions, *args, **kwargs)
6617 # For broadcastable series, use no rows.
6618 parts = [
6619 d._meta
6620 if _is_broadcastable(d)
(...)
6624 for d in dasks
6625 ]
-> 6626 with raise_on_meta_error(funcname(op)):
6627 meta = partial_by_order(*parts, function=op, other=other)
6629 result = new_dd_object(graph, _name, meta, divisions)

File d:\Yifan_Wang\Software\envs\SP\lib\contextlib.py:153, in _GeneratorContextManager.exit(self, typ, value, traceback)
151 value = typ()
152 try:
--> 153 self.gen.throw(typ, value, traceback)
154 except StopIteration as exc:
155 # Suppress StopIteration unless it's the same exception that
156 # was passed to throw(). This prevents a StopIteration
157 # raised inside the "with" statement from being suppressed.
158 return exc is not value

File d:\Yifan_Wang\Software\envs\SP\lib\site-packages\dask\dataframe\utils.py:216, in raise_on_meta_error(funcname, udf)
207 msg += (
208 "Original error is below:\n"
209 "------------------------\n"
(...)
213 "{2}"
214 )
215 msg = msg.format(f" in {funcname}" if funcname else "", repr(e), tb)
--> 216 raise ValueError(msg) from e

ValueError: Metadata inference failed in or_.

Original error is below:

ValueError('Unable to coerce to Series, length must be 11: given 2')

Traceback:

File "d:\Yifan_Wang\Software\envs\SP\lib\site-packages\dask\dataframe\utils.py", line 195, in raise_on_meta_error
yield
File "d:\Yifan_Wang\Software\envs\SP\lib\site-packages\dask\dataframe\core.py", line 6627, in elemwise
meta = partial_by_order(*parts, function=op, other=other)
File "d:\Yifan_Wang\Software\envs\SP\lib\site-packages\dask\utils.py", line 1476, in partial_by_order
return function(*args2, **kwargs)
File "d:\Yifan_Wang\Software\envs\SP\lib\site-packages\pandas\core\ops\common.py", line 76, in new_method
return method(self, other)
File "d:\Yifan_Wang\Software\envs\SP\lib\site-packages\pandas\core\arraylike.py", line 82, in ror
return self.logical_method(other, roperator.ror)
File "d:\Yifan_Wang\Software\envs\SP\lib\site-packages\pandas\core\frame.py", line 7910, in _arith_method
self, other = self._align_for_op(other, axis, flex=True, level=None)
File "d:\Yifan_Wang\Software\envs\SP\lib\site-packages\pandas\core\frame.py", line 8187, in _align_for_op
right = to_series(right)
File "d:\Yifan_Wang\Software\envs\SP\lib\site-packages\pandas\core\frame.py", line 8133, in to_series
raise ValueError(

Guide de contribution

Ouvrir le guide de contribution

Par où commencer

  1. Lisez l'issue en entier, puis le guide de contribution du projet.
  2. Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
  3. Forkez le dépôt et travaillez sur une branche.
  4. Ouvrez une pull request qui référence le numéro de l'issue.

Piste de recherche

Commencez par reproduire l’opération de notebook signalée qui combine my_images, my_labels, filtered_data, my_shapes et my_tables après avoir sélectionné un sous-ensemble de sdata["transcripts"] par z. Lisez les points d’entrée existants de visualisation 2D de Xenium et examinez la manière dont les données de transcrits sont reconstruites ; aucun fichier source ni test n’est nommé dans l’issue. Le travail serait considéré comme terminé lorsqu’un chemin de visualisation 3D défini ou une limitation documentée sera disponible, avec la résolution du ValueError signalé ou son isolement plus clair.

Rédigé par le modèle d'indexation à partir du texte de l'issue.

Évaluation

Stack technique
pandas, python
Domaine
data-visualization
Type d'issue
Fonctionnalité
Difficulté
5/5
Temps estimé
Plus d'une semaine
Activité
À l'abandon
Clarté
À clarifier
Accessibilité débutants
25/100

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.