1 | initial version |
I think you shouldn't put the cython definition and the interact in the same cell, because the cython cell will call a C compiler and will be quite expensive to execute. It doesn't make sense to weigh down every execution of the interact by the C compiler call.
Anyway, you can avoid the %cython
magic and calling the cython environment from python:
cython("""
def function(...):
...
""")
@interact
def wrappe(...):
....