Timer unit: 1e-06 s Total time: 0 s File: /Users/tillhoffmann/temp/test.pyx Function: cumulative_sum at line 1 Line # Hits Time Per Hit % Time Line Contents ============================================================== 1 def cumulative_sum(int n): 2 cdef int s = 0, i 3 for i in range(n): 4 s += i 5 6 return s
from distutils.core import setupfrom Cython.Build import cythonizefrom Cython.Compiler.Options import directive_defaultsfrom distutils.extension import Extension
directive_defaults['profile'] = Truedirective_defaults['linetrace'] = Truedirective_defaults['binding'] = True
sourcefiles = ['test.pyx']extensions = [Extension("test", sourcefiles, define_macros=[('CYTHON_TRACE', '1')])]setup(ext_modules = cythonize(extensions))
Hi,
I just wanted to follow up on this discussion. The line profiler works nicely for module-level `def` functions, thank you. Do you know whether it's possible to support instance-level `def` functions?
You received this message because you are subscribed to a topic in the Google Groups "cython-users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/cython-users/FH3TYK8BkeA/unsubscribe.
To unsubscribe from this group and all its topics, send an email to cython-users...@googlegroups.com.