You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am attempting to adapt the meepcon tutorial with mode decomposition. The simulation as it is created can be run without problem but as soon as I add add_flux, or add_mode_monitor to the simulation, I get this error
tutorial3.py 132 <module>
sim.run(until_after_sources=mp.stop_when_fields_decayed(
simulation.py 4443 run
self._evaluate_dft_objects()
simulation.py 2889 _evaluate_dft_objects
dft.swigobj = dft.func(*dft.args)
simulation.py 3416 _add_flux
return self._add_fluxish_stuff(
simulation.py 3718 _add_fluxish_stuff
vol_list.__swig_destroy__(vol_list)
AttributeError:
'NoneType' object has no attribute '__swig_destroy__'
With add_mode_monitor, the error is different but is happening at the same place
tutorial3.py 158 <module>
sim.run(until_after_sources=mp.stop_when_fields_decayed(
simulation.py 4443 run
self._evaluate_dft_objects()
simulation.py 2889 _evaluate_dft_objects
dft.swigobj = dft.func(*dft.args)
simulation.py 3442 _add_mode_monitor
raise ValueError(
ValueError:
add_mode_monitor expected just one ModeRegion. Got 0
The code is below, everything above line 117 is unchanged from the original tutorial
The problem is actually with simulation.add_flux. If an argument is passed as a keyword argument, the function does not execute properly. For example in the code above, add_flux was called like sim.add_flux(fcen, 0, 1, Fluxregion=fluxregion) which caused the 'NoneType' object has no attribute '__swig_destroy__' error.
I am attempting to adapt the meepcon tutorial with mode decomposition. The simulation as it is created can be run without problem but as soon as I add add_flux, or add_mode_monitor to the simulation, I get this error
With add_mode_monitor, the error is different but is happening at the same place
The code is below, everything above line 117 is unchanged from the original tutorial
The text was updated successfully, but these errors were encountered: