Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

For any type of tile there should be a class or method returning pixel coordinates in this ideal geometry,

            (x, y, z)               xarr, yarr, zarr = get_pixelxyz_maps_xyzum(row,column)

For example,

or look-up tables for consecutive pixel indexes

Python interface for CSPAD2x1

Code Block
from PyCSPadImage.PixCoords2x1 import cspad2x1_one
    ...
 xarr, yarr, zarr = cspad2x1_one.get_xyz_maps_um()

returns x-, y-, and z-coordinate arrays of shape [185,388]              (xarr, yarr, zarr) = get_pixel_xyz_arrays().

 

 

Memory model

It is assumed that each tile is presented in DAQ or offline data by a consecutive block of memory.  Uniform matrix-type geometry of pixel array is preferable, but  other geometry can be handled.  For example, for CSPAD 2x1 sensor pixel index in the tile memory block of size (185,388) can be evaluated as

...

  • tile ideal geometry,
  • tile center positions,
  • tile N·90 rotation and tilt angles:

             (x,y,z)in detector = (Xc,Yc,Zc) + R(N·90+tilt) × (x,y,z)in tile,

  • .

Then all rotations and translations are defined as:

Code Block
#file: pyimgalgos/src/GeometryObject.py

def rotation(X, Y, C, S) :
    Xrot = X*C - Y*S 
    Yrot = Y*C + X*S 
    return Xrot, Yrot

class GeometryObject :
    ...
    def transform_geo_coord_arrays(self, X, Y, Z) :
        ...
	    # define Cx, Cy, Cz, Sx, Sy, Sz - cosines and sines of rotation + tilt angles
        ...

        X1, Y1 = rotation(X,  Y,  Cz, Sz)
        Z2, X2 = rotation(Z,  X1, Cy, Sy)
        Y3, Z3 = rotation(Y1, Z2, Cx, Sx)

        Zt = Z3 + self.z0
        Yt = Y3 + self.y0
        Xt = X2 + self.x0

        return Xt, Yt, Zt 

where the 3-d where rotation matrix R is a product of three 2-d rotations around appropriate axes,

...

Pixel coordinates in the detector should be accessed by a method like

            (x, y, z)               xarr, yarr, zarr = get_pixel_xyz_in_detector(tile_number,row,column),

or look-up tables for consecutive pixel indexes

coords().

For example, Python interface for CSPAD

Code Block
from pyimgalgos.GeometryAccess import GeometryAccess
    ...
    fname_geometry='<path>/geometry/0-end.data'
    geometry = GeometryAccess(fname_geometry)
    X,Y,Z = geometry.get_pixel_coords()

 

               (xarr, yarr, zarr) = get_pixel_xyz_arrays_in_detector().

 

Summary

Suggested method for imaging detector geometry description provides simple and unambiguous way of pixel coordinate parametrization. This method utilizes all available information from optical measurement and design of the detector and tiles. All geometry parameters are extracted without fitting technique and presented by natural intuitive way.

...