Open bergkvist opened 4 years ago
The following snippet might work. Not sure about Cython support though
from memory_profiler import LineProfiler, show_results
profile = LineProfiler()
profile.add_function(_geometry_from_xy)
profile(_geometry_from_xy)(lon, lat, coord_count)
show_results(profile)
Trying to use it like line_profiler doesn't work
I get an error
Note that I cannot use the
@profile
decorator - because I'm trying to profile a Cython function. I also want the profiling to run as part of my CI/CD - without being present in production code.