mcot.surface.test_data¶
Functions
|
Creates a cortex with a WM/GM boundary (at radius of 1) and a pial surface (at a radius of 2) |
|
Converts mesh to cortical surface by defining it as left or right cortex. |
Reads all surfaces in the fsaverage directory. |
|
Reads the left pial surface from the fsaverage directory. |
|
|
generate a rectangle as triangular mesh. |
|
Generates a mesh of a unit sphere with norient vertices per hemisphere. |
|
Draws triangle between (0, 0), (1, 0), (0, 1) |
create_spherical_cortex¶
- mcot.surface.test_data.create_spherical_cortex(norient=300) mcot.surface.cortex.Cortex [source]¶
Creates a cortex with a WM/GM boundary (at radius of 1) and a pial surface (at a radius of 2)
- Parameters
norient – number of vertices on the sphere
- Returns
spherical cortex
mesh_to_cortex¶
- mcot.surface.test_data.mesh_to_cortex(mesh: mcot.surface.mesh.Mesh2D, cortex='left') mcot.surface.cortical_mesh.CorticalMesh [source]¶
Converts mesh to cortical surface by defining it as left or right cortex.
- Parameters
mesh – surface mesh
cortex – ‘left’ or ‘right’, defining which cortex this should represent
- Returns
same mesh but as a CorticalMesh
read_fsaverage_cortex¶
read_fsaverage_surface¶
rectangle¶
- mcot.surface.test_data.rectangle(size=(1.0, 1.0, 1.0), inward_normals=True)[source]¶
generate a rectangle as triangular mesh.
- Parameters
size – rectangle size (in arbitrary units)
inward_normals – ensure the normals are pointing inwards (otherwise they point in random directions.
- Returns
triangular mesh covering the surface of a rectangle
- Return type
sphere¶
- mcot.surface.test_data.sphere(norient=300) mcot.surface.mesh.Mesh2D [source]¶
Generates a mesh of a unit sphere with norient vertices per hemisphere.
- Parameters
norient – number of vertices
- Returns
mesh of sphere with radius 1
triangle_mesh¶
- mcot.surface.test_data.triangle_mesh(ndim=3) mcot.surface.mesh.Mesh2D [source]¶
Draws triangle between (0, 0), (1, 0), (0, 1)
- Parameters
ndim – number of dimensions of the space (triangle will be in the first two)
- Returns
mesh