hcosmo file reading method modified