-
Notifications
You must be signed in to change notification settings - Fork 40
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
PyFMI 2.16.2 - problem with conda-forge installation #287
Comments
Hi @janpeter19. It seems strange that you are seeing that error, it makes me believe something is wrong with the compiled Cython-files, or at least in the sense it is not compatible with your environment.
Regarding Python 3.10/3.11 or 3.12, I believe any should be OK to use. You can see the from the suffixes that all of those Python versions are supported: https://anaconda.org/conda-forge/pyfmi/files |
Hi @modelonrobinandersson. The FMUs are made in OpenModelica in Ubuntu 22.04 LTS with gcc 11.4.0. A related problem (perhaps) that I have lived with (for a long time) also with PyFMI 2.16.1, is that I have got warnings related to Assimulo and numerical algorithms that after all do not have any impact on the results, what I can see. Still an indiction of something not ok. Screenshot enclosed. |
Hi @jschueller, is this something you have seen before and perhaps can share some guidance on? |
it works fine for me from a clean miniforge install |
Hi @janpeter19 could you share what commando you use to install? Based on jschuellers comment above it seems to be working fine. I also wonder if you try to uninstall assimulo and pyfmi (or simply create a new virtual environment and attempt to install both pyfmi and assimulo there), do you still see the same issues? |
Hi @modelonrobinandersson. You have the script on Github here as a Google Colab notebook. From your web-browser (and you need a gmail-adress) you can run the script using the virtual machine associated to you gmail-account. You just under heading "Runtime" choose "Run all" and you will see step by step what the commands are and what is happening. In cell #9 you get an error message that load_fmu cannot be imported since "pyfmi.fmi" cannot be found. I just checked it again and it still does not work! I have got the comment last year that I could try miniforge, but I am not convinced. After all I have used miniconda and conda-forge many years and the alternative for me is the package FMPy and that works just fine with miniconda and conda-forge. So please try! |
your script seems to be mixing packages from the "defaults" repo as well as conda-forge, this is not supported see: |
@jschueller !conda config --set channel_priority strict Then the installation takes very, very long time I would appreciate a bit more detailed help. Thank you. |
@jschueller But I get the same error as before: No module named 'pyfmi.fmi' The updated script you find here: I would appreciate a bit more detailed help. Thank you! |
Please try using miniforge |
Hi @janpeter19 I see that you first use Python
and also In general when you see error |
Hi @modelonrobinandersson. I also note that PyFMI is updated to 2.16.3 that may, or may not have any impact here. |
Hi @janpeter19, glad to hear it is working. I am closing this issue now but if you feel like it is not resolved feel free to open it again. |
You can close it. The error text in my second note above, I may come back to in a separate question. Can live with it. |
Hi,
In install PyFMI 2.16.2 using conda from conda-forge into Ubuntu 22.04 LTS and it does not wok. (I use Python 3.10.16 and Numpy 2.2.2 and Assimulo 3.6.0).
The problem is that pyfmi installation seems to work.
But when I do
from pyfmi import load_fmu
Then error message:
ModuleNotFoundError: No module named 'pyfmi.fmi'
If I check installation with
!conda list
or
!pip show pyfmi
it is there
Further it seems also not possible to now use the earlier PyFMI version 2.16.1
Here is perhaps some similarity (but also differences) with case #236 but not sure at all. What I do see is that here is a recent change to use Assimulo 3.6.0 that may have created my problems. But not sure at all.
Would be good to know if you still recommend to stay with Python 3.10 or I can use 3.11 or preferably 3.12. FMPy I run with Python 3.12 and would be good to have the same.
Jan Peter
PS. Test cases you have here https://github.com/janpeter19
The text was updated successfully, but these errors were encountered: