Commit d1867509 authored by payno's avatar payno
Browse files

[nxtomomill.utils][__insert_in_vds] handle use case when data_frm_url is 2D instead of 3D

parent 11169b38
Pipeline #55815 failed with stages
in 1 minute and 9 seconds
......@@ -612,7 +612,13 @@ class _FrameAppender:
self.__insert_in_vds(h5s, url, data_frm_url)
def __insert_in_vds(self, h5s, url, data_frm_url):
n_frames, dim_2, dim_1 = data_frm_url.shape
if data_frm_url.ndim == 2:
n_frames = 1
dim_2, dim_1 = data_frm_url.shape
elif data_frm_url.ndim == 3:
n_frames, dim_2, dim_1 = data_frm_url.shape
else:
raise ValueError("data to had is expected to be 2 or 3 d")
virtual_sources_len = []
virtual_sources = []
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment