solved merge conflict
Build on RHEL9 / buildh (push) Failing after 1m22s

This commit is contained in:
Mazzoleni Alice Francesca
2025-04-10 09:21:50 +02:00
36 changed files with 1685 additions and 54 deletions
+3 -3
View File
@@ -2,8 +2,8 @@
from . import _aare
# from ._aare import File, RawMasterFile, RawSubFile
# from ._aare import Pedestal_d, Pedestal_f, ClusterFinder, VarClusterFinder
from ._aare import File, RawMasterFile, RawSubFile, JungfrauDataFile
from ._aare import Pedestal_d, Pedestal_f, ClusterFinder, VarClusterFinder
from ._aare import DetectorType
from ._aare import ClusterFile_Cluster3x3i as ClusterFile
from ._aare import hitmap
@@ -17,7 +17,7 @@ from .CtbRawFile import CtbRawFile
from .RawFile import RawFile
from .ScanParameters import ScanParameters
from .utils import random_pixels, random_pixel, flat_list
from .utils import random_pixels, random_pixel, flat_list, add_colorbar
#make functions available in the top level API
+10 -1
View File
@@ -1,4 +1,6 @@
import numpy as np
import matplotlib.pyplot as plt
from mpl_toolkits.axes_grid1 import make_axes_locatable
def random_pixels(n_pixels, xmin=0, xmax=512, ymin=0, ymax=1024):
"""Return a list of random pixels.
@@ -24,4 +26,11 @@ def random_pixel(xmin=0, xmax=512, ymin=0, ymax=1024):
def flat_list(xss):
"""Flatten a list of lists."""
return [x for xs in xss for x in xs]
return [x for xs in xss for x in xs]
def add_colorbar(ax, im, size="5%", pad=0.05):
"""Add a colorbar with the same height as the image."""
divider = make_axes_locatable(ax)
cax = divider.append_axes("right", size=size, pad=pad)
plt.colorbar(im, cax=cax)
return ax, im, cax