diff --git a/schainpy/model/graphics/figure.py b/schainpy/model/graphics/figure.py index 508aa2a..3b0d1c3 100644 --- a/schainpy/model/graphics/figure.py +++ b/schainpy/model/graphics/figure.py @@ -312,7 +312,7 @@ class Axes: decimationy = None __MAXNUMX = 200 - __MAXNUMY = 100 + __MAXNUMY = 400 __MAXNUMTIME = 500 @@ -501,15 +501,13 @@ class Axes: xlen = len(x) ylen = len(y) - decimationx = int(xlen/self.__MAXNUMX)+1 \ - if int(xlen/self.__MAXNUMX)>1 else 1 - decimationy = int(ylen/self.__MAXNUMY) \ - if int(ylen/self.__MAXNUMY)>1 else 1 + decimationx = numpy.floor(xlen/self.__MAXNUMX) - 1 if numpy.floor(xlen/self.__MAXNUMX)>1 else 1 + decimationy = numpy.floor(ylen/self.__MAXNUMY) + 1 + x_buffer = x#[::decimationx] y_buffer = y#[::decimationy] z_buffer = z#[::decimationx, ::decimationy] - #=================================================== if self.__firsttime: @@ -565,9 +563,9 @@ class Axes: maxNumX = self.__MAXNUMTIME if maxNumY == None: - maxNumY = self.__MAXNUMY + maxNumY = self.__MAXNUMY - if self.__firsttime: + if self.__firsttime: self.z_buffer = z self.x_buffer = numpy.hstack((self.x_buffer, x)) @@ -606,10 +604,8 @@ class Axes: xlen = len(self.x_buffer) ylen = len(y) - decimationx = int(xlen/self.__MAXNUMX) \ - if int(xlen/self.__MAXNUMX)>1 else 1 - decimationy = int(ylen/self.__MAXNUMY) \ - if int(ylen/self.__MAXNUMY)>1 else 1 + decimationx = numpy.floor(xlen/maxNumX) + 1 + decimationy = numpy.floor(ylen/maxNumY) + 1 x_buffer = self.x_buffer#[::decimationx] y_buffer = y#[::decimationy]