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

Fix PyChaste Build for Chaste 2024.1 #64

Merged
merged 42 commits into from
Apr 15, 2024
Merged

Fix PyChaste Build for Chaste 2024.1 #64

merged 42 commits into from
Apr 15, 2024

Conversation

kwabenantim
Copy link
Member

@kwabenantim kwabenantim self-assigned this Feb 28, 2024
@kwabenantim kwabenantim linked an issue Feb 28, 2024 that may be closed by this pull request
6 tasks
@kwabenantim kwabenantim added the bug Something isn't working label Feb 28, 2024
@kwabenantim
Copy link
Member Author

The bindings seem to be having problems finding the constructors for MutableElement<1,2>, which is needed by ImmersedBoundaryElement<2,2>:

/usr/bin/ld:
CMakeFiles/_chaste_project_PyChaste_mesh.dir/dynamic/wrappers/mesh/MutableElement1_2.cppwg.cpp.o: 
in function `MutableElement<1u, 2u>* pybind11::detail::initimpl::construct_or_initialize<MutableElement<1u, 2u>, unsigned int, 0>(unsigned int&&)':
~/PyChaste/dynamic/pybind11/include/pybind11/detail/init.h:76: 
undefined reference to `MutableElement<1u, 2u>::MutableElement(unsigned int)'

/usr/bin/ld: 
CMakeFiles/_chaste_project_PyChaste_mesh.dir/dynamic/wrappers/mesh/MutableElement1_2.cppwg.cpp.o: 
in function `MutableElement1_2_Overloads::MutableElement(unsigned int)':
~/Chaste/projects/PyChaste/dynamic/wrappers/mesh/MutableElement1_2.cppwg.cpp:19: 
undefined reference to `MutableElement<1u, 2u>::MutableElement(unsigned int)'

collect2: error: ld returned 1 exit status

@kwabenantim
Copy link
Member Author

kwabenantim commented Mar 19, 2024

import chaste.visualization
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "~/pychaste-env/lib/python3.10/site-packages/chaste/visualization/__init__.py", line 38, in <module>
    from chaste.visualization.fortests import *
  File "~/pychaste-env/lib/python3.10/site-packages/chaste/visualization/fortests.py", line 45, in <module>
    import chaste.cell_based
  File "~/pychaste-env/lib/python3.10/site-packages/chaste/cell_based/__init__.py", line 40, in <module>
    from chaste.cell_based._chaste_project_PyChaste_cell_based import *
ImportError: arg(): could not convert default argument 
'pOdeSolver: boost::shared_ptr<AbstractCellCycleModelOdeSolver>' in 
method '<class 'chaste.cell_based._chaste_project_PyChaste_cell_based.TysonNovakCellCycleModel'>.__init__' 
into a Python object (type not registered yet?)

@kwabenantim
Copy link
Member Author

import chaste.cell_based
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "~/pychaste-env/lib/python3.10/site-packages/chaste/cell_based/__init__.py", line 40, in <module>
    from chaste.cell_based._chaste_project_PyChaste_cell_based import *
ImportError: generic_type: type "AbstractCellCycleModel" is already registered!

@kwabenantim
Copy link
Member Author

The registration issues were corrected by fixing the registration order in 3fe4c00

@kwabenantim
Copy link
Member Author

Immersed Boundary Tutorial and visualization are working okay except for an error in the last example with a FluidSource:

---------------------------------------------------------------------------
RuntimeError                              Traceback (most recent call last)
/tmp/ipykernel_57426/1620215830.py in <module>
      6 simulator.SetEndTime(1000 * dt)
      7 # Perform the simulation
----> 8 simulator.Solve()
      9 # Visualize the end state
     10 nb_manager.vtk_show(scene, height=300)

RuntimeError: 
Chaste error: ./mesh/src/utilities/ObsoleteBoxCollection.cpp:123: Location in dimension 0 is -nan which is not in the domain [0, 1].

@kwabenantim
Copy link
Member Author

kwabenantim commented Apr 11, 2024

Immersed Boundary Tutorial and visualization are working okay except for an error in the last example with a FluidSource:

Fixed in 1f56164 by reducing the simulation run length to the value in the original C++ tutorial.

@kwabenantim kwabenantim marked this pull request as ready for review April 11, 2024 12:28
@kwabenantim kwabenantim added the enhancement New feature or request label Apr 11, 2024
@kwabenantim kwabenantim merged commit 0be20da into develop Apr 15, 2024
3 checks passed
@kwabenantim kwabenantim deleted the release-2024.1 branch April 15, 2024 13:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Release PyChaste 2024.1
1 participant