spectralpython / spectral

Python module for hyperspectral image processing
MIT License
571 stars 139 forks source link

Handle ENVI headers for PCI images #74

Open tboggs opened 6 years ago

tboggs commented 6 years ago

ENVI headers with file type = PCI require special read procedures to access the data in the image file (see issue #72). Should either add support for reading these images or raise an exception or warning for PCI images.

pythonic2020 commented 3 years ago

Has this enhancement been implemented? I tried reading a .pix PCI cube with a .pix.hdr file, and the image is all distorted when I view it. The image displays normally in ENVI. Image below is from viewing a 1000x1000 subset of the imported image using spectral imshow.

Figure 6

tboggs commented 3 years ago

No, it has not been implemented. If I had access to the pci_read_spatial and pci_read_spectral routines referenced in issue #72, I could probably implement it. In the mean time, you can likely get around it by adjusted the samples parameter in the header file to account for the additional data being appended to each line.

pythonic2020 commented 3 years ago

I have the pci_read_spatialand pci_read_spectral in my header also. I'll look into changing the samples param. Thank you!!!! :-)