refactored dtype.h to move python friendly format