working on hyper spectral code