TimeSeries & cython: why cimport yellow?

asked 2014-08-08 22:04:49 +0100

Rolandb gravatar image

updated 2014-08-08 22:10:16 +0100

I get the following information from cython:

Raw output

6: from sage.finance.time_series cimport TimeSeries
7: 
8:   cpdef csnelregres(self,int periode):
9:       cdef int aantal=len(self)-periode
10:   
11:     cpdef a = TimeSeries(aantal)

I wasn't expecting a yellow color for cpdef a = TimeSeries(aantal).

Any suggestions?

edit retag flag offensive close merge delete

Comments

Has this something to do with sage ? Maybe this is rather related to your text editor or shell or whatever you use when you see this yellow color ?

FrédéricC gravatar imageFrédéricC ( 2014-08-10 11:45:54 +0100 )edit

@FrédéricC: when you run cython code, it gets compiled and there is a way to view the code with different shades of yellow background colouring that indicates the level of speedup for each part of the code. The least accelerated by cythonization, the yellower, if I remember correctly.
@Rolandb: maybe you can provide a bit more context: give steps for people to be able to easily reproduce what you are doing and experiment from there.

slelievre gravatar imageslelievre ( 2014-08-10 16:58:15 +0100 )edit