nicomignoni/tab2img

Data values gets changed to 0-1 after reshaping the 1D to 2D from tab2img tool

Opened this issue · 3 comments

Hi, I want to confirm that does this tool changes the data values as well? Or does it simply reshapes the data of 1D to 2D?

I am passing the data of 1x198 shape and it is returning me the data of 1x15x15 shape which is perfect square of the closest 2 dimension. But the data values are also getting changed between the range of 0-1

No, data should not have their value changed, only reordered. If you attach the file containing your data, I can try to replicate your problem.

This is my first sample of input data of shape 197,
image
And this is the reshaped data which i get
image

This looks like very strange that when I run the code with the same data but with less features of 144 for the output of 12x12, my data does not change and the tab2img only reshapes the data

Input data of 144 features
image

Output contains the data reshaped to 12x12 and the original data values stayed the same as min value and max value
image

But if I increase the data features for the same dataset to 169 so that i get the output of 13x13, my data values gets changed

Input data of 169 features
image

Output data is of shape 13x13 but the data values are now only 0 or 1
image