ants.ops.reorient_image
Functions
|
Compute an image center of mass in physical space which is defined as the mean of the intensity weighted voxel coordinate system. |
|
|
|
Reorient an image. |
- get_center_of_mass(image)[source]
Compute an image center of mass in physical space which is defined as the mean of the intensity weighted voxel coordinate system.
ANTsR function: getCenterOfMass
- Parameters:
image (
ants.core.ANTsImage) – image from which center of mass will be computed- Return type:
scalar
Example
>>> fi = ants.image_read( ants.get_ants_data("r16")) >>> com1 = ants.get_center_of_mass( fi ) >>> fi = ants.image_read( ants.get_ants_data("r64")) >>> com2 = ants.get_center_of_mass( fi )