Hi Nick,
I guessed the machine stamp from MRC/CCP4 format description - half byte 01 means BE, half byte 04 means LE. Are these only applicable to intel machines? How are other machine architectures indicated? I do not know. We probably can find the authoritative answer from the CCP4 library, just need a little bit more time... The machine stamp itself should not be affected by the machine's architecture, because it needs to be read before the program knows what the architecture is. Therefore it should be a string instead of a number. In the MRC/CCP4 map specification, it says that only the first two bytes are used. I had seen some home-brew programs taking shortcuts by using the int value of the machine stamp word, and I thought that was smart. Now I realise that this practice has the risk of failing on non-intel machines. So, if it is meant to be half-bytes, interpret it as half bytes! Zhijie ________________________________ From: Nicholas Devenish <ndeven...@gmail.com> Sent: Wednesday, November 14, 2018 8:54 AM To: Zhijie Li Cc: CCP4BB@jiscmail.ac.uk Subject: Re: [ccp4bb] VERY old mtz file.. Hi Zhijie, Looks like we both had the same thoughts! On Wed, Nov 14, 2018 at 1:19 PM Zhijie Li <zhijie...@utoronto.ca<mailto:zhijie...@utoronto.ca>> wrote: The semi....BE.mtz has the big endian stamp (0x11 11 00 00 at bytes 9-12 ) put in the header of the original file; everything else is untouched Is this correct? I thought machine stamp was supposed to be the 4-bit sizes of int, real, complex and char e.g. all the little endian MTZ's I've seen have 0x44 41 00 00, which would make the big-endian version 0x00 00 41 44. Then again, mtzdmp complained regardless, and perhaps I've just misinterpreted the documentation (I'd love to know if this was the case!) Thanks, Nick ######################################################################## To unsubscribe from the CCP4BB list, click the following link: https://www.jiscmail.ac.uk/cgi-bin/webadmin?SUBED1=CCP4BB&A=1