mattjj / pyhsmm-factorial

MIT License
18 stars 9 forks source link

pyhsmm-factorial example does not work with iPython notebook #6

Open ianlcassidy opened 9 years ago

ianlcassidy commented 9 years ago

When I change T to any value other than 400 in iPython notebook, I get lots of warnings followed by a CompileError. This occurs when I run the "posteriormodel.resample_model" line. If I run the example in my terminal (not using iPython notebook), I sometimes get warnings for different values of T, but not errors.

mattjj commented 9 years ago

Maybe something about weave doesn't work in the notebook (or with the particular way you're running the notebook). It could be that 400 works because it's reading a cached code file, either from an earlier execution of the notebook or a terminal session.

You could try deleting the weave code cache or editing the weave inline command to force recompilation.

The real solution is to replace all the weave stuff with cython, as in the pyhsmm master. Pull requests welcome :)