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

error:TypeError: __init__() missing 1 required positional argument: 'linear_solver' when "Solve the TranslationProblem" #805

Open
losechester opened this issue Feb 26, 2025 · 1 comment

Comments

@losechester
Copy link

I ran the same code as the official tutorial "Translating multiomics single-cell data" used.Everything was fine until I started to run "solve Solve the [TranslationProblem]".What is 'linear_solver' and how to fix it?Please help me ><
error:
INFO Solving 1 problems
INFO Solving problem OTProblem[stage='prepared', shape=(6224, 6224)].
Traceback (most recent call last):
File "d:\test\moscottest.py", line 58, in
tp = tp.solve(alpha=1.0, epsilon=1e-3)
File "C:\Users\abc\AppData\Local\Programs\Python\Python39\lib\site-packages\moscot\problems\cross_modality_translation.py", line 290, in solve
return super().solve(
File "C:\Users\abc\AppData\Local\Programs\Python\Python39\lib\site-packages\moscot\base\problems\compound_problem.py", line 353, in solve
_ = problem.solve(**kwargs)
File "C:\Users\abc\AppData\Local\Programs\Python\Python39\lib\site-packages\moscot\base\problems_utils.py", line 548, in wrap_solve
instance = wrapped(*args, **kwargs)
File "C:\Users\abc\AppData\Local\Programs\Python\Python39\lib\site-packages\moscot\base\problems\problem.py", line 428, in solve
self._solver = solver_class(**init_kwargs)
File "C:\Users\abc\AppData\Local\Programs\Python\Python39\lib\site-packages\moscot\backends\ott\solver.py", line 365, in init
self._solver = gromov_wasserstein.GromovWasserstein(
TypeError: init() missing 1 required positional argument: 'linear_solver'

@MUCDK
Copy link
Collaborator

MUCDK commented Feb 26, 2025

Hi,

This is probably due to a wrong ott-jax version.

Which version of ott-jax and moscot are you using?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants