S4
S4 copied to clipboard
Update on python API to correct undefined references
Since the migration to the new C API the python module stop working as expected. A few errors appear after import:
- undefined functions:
Layer_Init
,Material_Init
,Material_InitTensor
,Simulation_AddMaterial
,Simulation_GetPoyntingFlux
andSimulation_MakeExcitationExterior
- The
SetFrequency
stop detroying previous results.
All these dependencies to the old API have been corrected by upgrading to the new C API when possible.
Old API calls still remains, although the python extension is more useful that the current version.
Works like a charm! Thanks so much for making these corrections.
@kwrobert After sending the pull request I noticed that some of functions which still use the old API are not working properly. For example, I fixed S4Sim_SetRegionCircle
in my fork, because is one of the functions I use most. Probably it is a better a idea to wait until S4v2
is merged with master
to implement all the changes.
I get a
ImportError: /home/chronum/S4/jmllorens/S4/build/lib.linux-x86_64-3.6/S4.cpython-36m-x86_64-linux-gnu.so: undefined symbol: PyInt_AsLong
when working with this. Any ideas?