Helper function to convert inhomogenous contours to rectangular array.
Zarr v3 does not support “object” dtype which was used as to wrap
inhomogenous arrays while saving using Zarr v2. This function creates
“rectangular” arrays for saving to Zarr.
Parameters:
contours (list(np.ndarray)) – List of numpy arrays of inconsistent lengths.
pad_value (int | None) – Values to pad to create rectangular array.