Always cache `read_slc` alongside y-mnmx values
parent
23c03a0905
commit
da618e1d38
|
@ -388,9 +388,11 @@ class Viz(msgspec.Struct): # , frozen=True):
|
||||||
f'{self.name} CACHED maxmin\n'
|
f'{self.name} CACHED maxmin\n'
|
||||||
f'{ixrng} -> {cached_result}'
|
f'{ixrng} -> {cached_result}'
|
||||||
)
|
)
|
||||||
|
read_slc, mxmn = cached_result
|
||||||
return (
|
return (
|
||||||
ixrng,
|
ixrng,
|
||||||
cached_result,
|
read_slc,
|
||||||
|
mxmn,
|
||||||
)
|
)
|
||||||
|
|
||||||
# get relative slice indexes into array
|
# get relative slice indexes into array
|
||||||
|
@ -451,10 +453,11 @@ class Viz(msgspec.Struct): # , frozen=True):
|
||||||
|
|
||||||
# cache result for input range
|
# cache result for input range
|
||||||
assert mxmn
|
assert mxmn
|
||||||
self._mxmns[ixrng] = mxmn
|
self._mxmns[ixrng] = (read_slc, mxmn)
|
||||||
profiler(f'yrange mxmn cacheing: {x_range} -> {mxmn}')
|
profiler(f'yrange mxmn cacheing: {x_range} -> {mxmn}')
|
||||||
return (
|
return (
|
||||||
ixrng,
|
ixrng,
|
||||||
|
read_slc,
|
||||||
mxmn,
|
mxmn,
|
||||||
)
|
)
|
||||||
|
|
||||||
|
@ -1026,12 +1029,10 @@ class Viz(msgspec.Struct): # , frozen=True):
|
||||||
)
|
)
|
||||||
|
|
||||||
if do_ds:
|
if do_ds:
|
||||||
|
# view.interaction_graphics_update_cycle()
|
||||||
view.maybe_downsample_graphics()
|
view.maybe_downsample_graphics()
|
||||||
view._set_yrange()
|
view._set_yrange()
|
||||||
|
|
||||||
# caller should do this!
|
|
||||||
# self.linked.graphics_cycle()
|
|
||||||
|
|
||||||
def incr_info(
|
def incr_info(
|
||||||
self,
|
self,
|
||||||
ds: DisplayState,
|
ds: DisplayState,
|
||||||
|
|
Loading…
Reference in New Issue