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

Not passing FMU Check #131

Open
sunne opened this issue Jun 22, 2021 · 8 comments
Open

Not passing FMU Check #131

sunne opened this issue Jun 22, 2021 · 8 comments

Comments

@sunne
Copy link

sunne commented Jun 22, 2021

Hi all,
The FMU checker provided in http://fmi-standard.org/ shows some issues when checking the fmu created with pythonfmu build.

@markaren
Copy link
Member

markaren commented Jun 22, 2021

InitialUnknowns? PythonFMU does not currently populate those. You might add them manually the information to your XML, but the importing tool may potentially discard this information anyway.

Note: The FMU should still be functional even though FMU Checker complains.

@sunne
Copy link
Author

sunne commented Jun 22, 2021

Yep, that's it. I have problems when importing the fmu into Adams Controls and I thought that was the problem. I fixed that, FMU Check says it's ok but Adams still does not like the created fmu. It's not a dependency problem, since I tried with a bare example, no module imports, only one input and one output, and the doStep() is empty (just pass).
I tried opening it with FMPy and it works.
It's probably another issue, or an issue for Adams but, has anyone opened a pythonfmu's fmu with Adams?
Thanks!

@markaren
Copy link
Member

If Adams internally loads Python, it will likely fail.

@sunne
Copy link
Author

sunne commented Jun 22, 2021

Yes, it does. It has an internal installation which may be accessed, thus additional packages may be installed. I installed pythonfmu there but still fails to load the fmu. Any additional thoughts on it?
Many thanks!

@markaren
Copy link
Member

So if Adams loads Python.dll (or .so on unix), and that dll is incompatible with the .dll expected by PythonFMU it just won't work.
If Adams loads Python 3.5 <= then it will fail no matter what. If the issue is bitness (e.g. Adams loads 32-bit Python), you could try compiling PythonFMU for 32-bit manually and use that.

@sunne
Copy link
Author

sunne commented Jun 23, 2021

According to the devs, it's Python 3.6.4 what's in the box. How can I compile PythonFMU for 32-bit manually? Many thanks!

(at this point, I think this could be more a Discussion than an Issue, idk if it's ok to keep it here...)

@markaren
Copy link
Member

markaren commented Jun 23, 2021

If Adams does use 32-bit Python, you could try to run https://github.com/NTNU-IHB/PythonFMU/blob/master/pythonfmu/pythonfmu-export/build_win.sh with -A Win32

Your Python installation then needs to be 32-bit as well.

That might work.

@sunne
Copy link
Author

sunne commented Jun 23, 2021

No need to check, it's 64-bit:
'3.6.4 (default, Feb 22 2018, 09:47:04) [MSC v.1912 64 bit (AMD64)]'
I've run out of ideas :)

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

No branches or pull requests

2 participants