You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As far as I am concerned, the huawei P20's raw image is 10bits dng files. but the data downloaded form the link http://people.ee.ethz.ch/~ihnatova/pynet.html#dataset are mixed with 8bits and 10bits png files. And the normalization code for training and testting in load_dataset.py at 21th line is shown below where the divisor is 4*255:
All image crops were saved as 4-channel 10-bit png files, though some of the crops correspond to dark image areas and thus their values might lie between 0 and 255. Therefore, some libraries might show that they are just 8-bit images since the values are lying in the 8-bit interval.
@aiff22
Thanks for your reply!
I try to save a ndarray with shape 448x448 which values lies between 0 and 255 by imageio.imwrite, no matter the ndarray's dtype is uint8 or uint16 , both of the png file saved have 8bit depth.
Thanks again!
As far as I am concerned, the huawei P20's raw image is 10bits dng files. but the data downloaded form the link http://people.ee.ethz.ch/~ihnatova/pynet.html#dataset are mixed with 8bits and 10bits png files. And the normalization code for training and testting in load_dataset.py at 21th line is shown below where the divisor is 4*255:
RAW_norm = RAW_combined.astype(np.float32) / (4 * 255)
Since there are part of data are 8bits depth, the divisor is too big for them.
And I tryed to used the pretrained model to test my own data captuered by huawei P20, the result is slightly overlighted.
So Is that a bug? or something far from my understand?
I try to fix this by replace the code in load_dataset.py at 21th line and re-train the model:
RAW_norm = RAW_combined.astype(np.float32) / (4 * 255)
by
if raw.dtype == np.uint16:
Is that correct?The text was updated successfully, but these errors were encountered: