moscot icon indicating copy to clipboard operation
moscot copied to clipboard

SinkhornProblem star policy wrong problem order

Open ArinaDanilina opened this issue 1 year ago • 4 comments

sp = SinkhornProblem(adata_red)
sp = sp.prepare(
    key="perturbation", joint_attr="X_pca", policy="star", reference="control"
)
sp = sp.solve(1e-2, 0.95, 0.95)
sp

generates SinkhornProblem[('Dacinostat (LAQ824)', 'control'), ('Givinostat (ITF2357)', 'control'), ('TAK-901', 'control'), ('Flavopiridol HCl', 'control')] but should be SinkhornProblem[('control', 'Dacinostat (LAQ824)'), etc ]

ArinaDanilina avatar Jan 29 '24 18:01 ArinaDanilina

@MUCDK why is this an issue? reference is always the target in star policy https://github.com/theislab/moscot/blob/ca135725193b70541f054d8cd853b0dee76f3bb0/src/moscot/utils/subset_policy.py#L312

giovp avatar Jan 30 '24 08:01 giovp

should we make it more flexible then? Here, the control should always be the source.

MUCDK avatar Jan 30 '24 09:01 MUCDK

I'd be ok with that, I just don't super see how this would change/unblock the perturbation setting. At the end of the day it is just convention right, since everything is symmetric in moscot?

giovp avatar Jan 30 '24 09:01 giovp

hi, I overlooked this issue from a long time ago. I don't understand if this is a design problem or a feature etc.

selmanozleyen avatar Sep 23 '24 21:09 selmanozleyen