GeezerVison is showing github.com — improvements for heatmap and histogram · Issue #86 · fastplotlib/fastplotlib
improvements for heatmap and histogram #86
Description
heatmap and histogram need some improvements, histogram is currently broken after #78
- heatmaps for data larger than 8192, as discussed before this is a WGPU limitation. Need to stitch together multiple
pygfx.Image world objects
- histogram is broken because histogram "data" is different from the graphic data. I think we should subclass
DataFeature to make one specific to histograms, and it could handle things like each bin and its values. We could add a method to HistogramGraphic to change the scale_factor for displaying it. We might also need to subclass ColorFeature for histograms so that indexing sets the color of each bin.
Activity
kushalkolar commented on Mar 1, 2023
Some ideas to help with tiling Image WorldObject for heatmaps:
from math import ceil
from itertools import product
chunk_size = 128
x_chunks = range(ceil(mcorr.shape[1] / chunk_size))
y_chunks = range(ceil(mcorr.shape[2] / chunk_size))
chunks = list(product(x_chunks, y_chunks))
# chunks is the position of each chunk
start_ixs = [list(map(lambda c: c * chunk_size, chunk)) for chunk in chunks]
stop_ixs = [list(map(lambda c: c + chunk_size, chunk)) for chunk in start_ixs]
grid = list()
for start, stop in zip(start_ixs, stop_ixs):
x0, y0 = start
x1, y1 = stop
grid.append(data[:, x0:x1, y0:y1].mean(0))kushalkolar commented on Mar 4, 2023
heatmap being done in #143
kushalkolar commented on Oct 28, 2023
So we've decided histogram is not happening because current libs more than good enough for histograms, as far as I've experienced.
Metadata
Metadata
Development
No branches or pull requestsIssue actions