Closed WeiweiAi closed 1 year ago
What output do you get when you run this script?
When I run it with the latest development codebase I get the following output:
no unresolved imports.
Validating the model
Validating the flat model
I got the following output:
no unresolved imports.
Validating the model
The method "validate_model" found 1 issues:
- Cyclic units exist: 'fmol' -> 'fmol'.
Validating the flat model
I think we have demonstrated that this issue will be resolved with the next release.
When I run the Python code using the new built bindings, I got the following error:
PS C:\Users\wai484\Documents\BG2CellML\test> python CyclicUnits_test1.py no unresolved imports. Validating the model Validating the flat model swig/python detected a memory leak of type 'std::shared_ptr< libcellml::Model > ', no destructor found. swig/python detected a memory leak of type 'std::shared_ptr< libcellml::Units > ', no destructor found. swig/python detected a memory leak of type 'std::shared_ptr< libcellml::Units > ', no destructor found. swig/python detected a memory leak of type 'std::shared_ptr< libcellml::Model > ', no destructor found. swig/python detected a memory leak of type 'std::shared_ptr< libcellml::Component > ', no destructor found. swig/python detected a memory leak of type 'std::shared_ptr< libcellml::Variable > ', no destructor found. swig/python detected a memory leak of type 'std::shared_ptr< libcellml::ImportSource > ', no destructor found. swig/python detected a memory leak of type 'std::shared_ptr< libcellml::Importer > ', no destructor found. swig/python detected a memory leak of type 'std::shared_ptr< libcellml::Model > *', no destructor found.
Not sure if this happens because something is wrong with the building process or relevant to the libcellml functions.
Best regards, Weiwei
On Wed, 10 May 2023 at 16:38, Hugh Sorby @.***> wrote:
I think we have demonstrated that this issue will be resolved with the next release.
— Reply to this email directly, view it on GitHub https://github.com/cellml/libcellml/issues/1166#issuecomment-1541340771, or unsubscribe https://github.com/notifications/unsubscribe-auth/ADRVM44CGCLHCO6NIFAWYQDXFMLSXANCNFSM6AAAAAAX4EBX2E . You are receiving this because you authored the thread.Message ID: @.***>
This is a separate issue and it has been reported here: https://github.com/cellml/libcellml/issues/1129 Still a work in progress at this point.
libcellml==0.4.0
I attach the Python script which shows the validator finds Cyclic units exist. After I flatten the model, the validation passed. I have checked the units definition but I could not find the cause of why the error occurred. Could you please help me with it? Thanks.