def _swaplch(LCH):
    "Reverse the order of an LCH numpy dstack or tuple for analysis."
    try: # Numpy array
        L,C,H = np.dsplit(LCH,3)
        return np.dstack((H,C,L))
    except: # Tuple
        L,C,H = LCH
        return H,C,L
def _swaplch ( LCH ) : try : L , C , H = np . dsplit ( LCH , 3 ) return np . dstack ( ( H , C , L ) ) except : L , C , H = LCH return H , C , L
Reverse the order of an LCH numpy dstack or tuple for analysis.