Yes, unfortunately an "orientation matrix" is completely useless without a frame of reference. All it does is tell you where the cell axes lie relative to "X", "Y" and "Z", but "X" may be the x-ray beam, or sometimes that is "Z" and "X" is the spindle axis. Different people have different and strongly-held opinions about this. The "fast" and "slow" axes on the detector are also a matter of widely-varying convention. The origin of the detector could be the first pixel in the image file, the upper-left corner, or it could be in "cameraman view" vs "sample view" and the beam center is also only meaningful relative to whatever the "origin" is. Also, if you are at one of the four beamlines in the world that rotates their spindle the opposite direction of everyone else, then you may have to reverse the sign of one axis as well, usually "Y", or there may be an option such as "REVERSEPHI". XDS lets you define all these things manually and there are formally no "default" settings.

To be fair, it is difficult for developers to keep track of what all ~150 beamlines around the world, plus commercial "home lab" equipment manufacturers are doing. I've been trying to some time to assemble a "library" of recent lysozyme datasets from as many beamlines as possible, but my collection is still far from complete:
http://bl831.als.lbl.gov/example_data_sets/

That said, I have written a few jiffies for inter-converting XDS and mosflm conventions, and posted them here:
http://bl831.als.lbl.gov/~jamesh/orientation_matrix/

Instructions are at the top of each awk script. For example, mosflm2xds.awk takes the first three lines to be the *.mat file from mosflm, but also needs the mosflm input script after that to figure out how to convert it into XDS conventions. Use it like this:
cat auto.mat mosflm.inp | ./mosflm2xds.awk >> XDS.INP

You can convert the resulting XDS keywords into an XPARM.XDS file using xds2xparm.awk, which can be useful for feeding into some pipelines. If you already have an XPARM.XDS, you can convert it back into XDS keywords using xparm2xds.awk, and these keywords can, in turn, be fed into xds2mosflm.awk to get a mosflm *.mat file again. Note, however, that there can be some information loss here. The *.mat file does NOT contain the full description of the detector and spindle geometry that XDS may be using. I make some guesses in these scripts if not all the relevant XDS keywords are provided. It works with my setup at ALS 8.3.1, but I have not tested it thoroughly with other cameras. I would be interested if you find any bugs!

As for what you're missing, could it perhaps be a reversed phi direction? That might look like a 180-degree rotation.

Good luck!

-James Holton
MAD Scientist

On 12/28/2014 3:12 PM, Igor Petrik wrote:

Takanori and Pierre,

Thank you for your quick responses. If you read my post you will see that I used the xds2mos.py script to convert the xds orientation to Mosflm format, but this gives me a result that is inconsistent with the matrix calculated directly by moslfm or DENZO. For orthorombic space group P222 there are only a hand full of equivalent matrices related by changing sign of one of the vectors. The matrices generated by XDS and Mosflm do not seem equivalent. Or maybe I'm missing something.

Thanks,
- Igor

Reply via email to