issue cast - jp2k
When trying to save as jp2k we get the following error
Saving data
Traceback (most recent call last):
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/bin/nabu", line 8, in <module>
sys.exit(main())
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/nabu/app/reconstruct.py", line 103, in main
R.reconstruct()
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/nabu/pipeline/fullfield/reconstruction.py", line 610, in reconstruct
self._reconstruct_chunked()
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/nabu/pipeline/fullfield/reconstruction.py", line 563, in _reconstruct_chunked
self.pipeline.process_chunk(task["sub_region"])
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/nabu/pipeline/fullfield/chunked.py", line 831, in process_chunk
self._process_chunk()
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/nabu/pipeline/fullfield/chunked.py", line 800, in _process_chunk
self._write_data()
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/nabu/pipeline/fullfield/chunked_cuda.py", line 132, in _write_data
super()._write_data(data=data)
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/nabu/pipeline/utils.py", line 31, in wrapper
res = func(*args, **kwargs)
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/nabu/pipeline/fullfield/chunked.py", line 742, in _write_data
self.writer.write_data(data)
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/nabu/pipeline/writer.py", line 186, in write_data
self.writer.save()
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/tomoscan/volumebase.py", line 408, in save
self.save_data(data_url, **kwargs)
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/tomoscan/esrf/volume/singleframebase.py", line 250, in save_data
frame_dumper[:] = frame
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/tomoscan/esrf/volume/singleframebase.py", line 281, in __setitem__
self.__callback(
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/tomoscan/esrf/volume/jp2kvolume.py", line 159, in save_frame
glymur.Jp2k(file_name, data=frame, psnr=self.psnr, cratios=self.cratios)
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/glymur/jp2k.py", line 278, in __init__
self._write(data)
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/glymur/jp2k.py", line 921, in _write
self._populate_cparams(img_array)
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/glymur/jp2k.py", line 895, in _populate_cparams
self._validate_compression_params(img_array, cparams)
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/glymur/jp2k.py", line 1025, in _validate_compression_params
self._validate_image_datatype(img_array)
File "/scisoft/tomotools/x86_64/cuda11/test_henri_2/lib/python3.8/site-packages/glymur/jp2k.py", line 1010, in _validate_image_datatype
raise InvalidJp2kError(msg)
glymur.jp2box.InvalidJp2kError: Only uint8 and uint16 datatypes are currently supported when writing.
a cast is most likely missing (to uint16 by default ?) config file is available here: entry0000_bambou_hercules_0001slice_001080.cfg