neuralib.widefield.ccf.RegionLabel

class neuralib.widefield.ccf.RegionLabel[source]

Bases: NamedTuple

Parameters:
  • acronym – Short uppercase code for the region (e.g. ‘VISp’).

  • name – Full name of the region.

  • reference – Depth reference range in microns (start, end) relative to brain surface.

  • resolution – Spatial sampling in microns per pixel.

  • label – Unique integer label for this region in a label map.

  • allen_id – Allen Brain Atlas identifier for the region.

  • allen_rgb – RGB color defined by the Allen Atlas for visualization.

  • left_center – (x, y) coordinates in mm of the centroid on the left hemisphere.

  • right_center – (x, y) coordinates in mm of the centroid on the right hemisphere.

  • left_x – 1D array of x-coordinates (mm) defining the left polygon boundary.

  • left_y – 1D array of y-coordinates (mm) defining the left polygon boundary.

  • right_x – 1D array of x-coordinates (mm) defining the right polygon boundary.

  • right_y – 1D array of y-coordinates (mm) defining the right polygon boundary.

__init__()

Methods

__init__()

count(value, /)

Return number of occurrences of value.

from_json(file, acronym)

index(value[, start, stop])

Return first index of value.

Attributes

acronym

Alias for field number 0

allen_id

Alias for field number 5

allen_rgb

Alias for field number 6

label

Alias for field number 4

left_center

Alias for field number 7

left_x

Alias for field number 9

left_y

Alias for field number 10

name

Alias for field number 1

reference

Alias for field number 2

resolution

Alias for field number 3

right_center

Alias for field number 8

right_x

Alias for field number 11

right_y

Alias for field number 12

acronym: str

Alias for field number 0

name: str

Alias for field number 1

reference: tuple[int, int]

Alias for field number 2

resolution: int

Alias for field number 3

label: int

Alias for field number 4

allen_id: int

Alias for field number 5

allen_rgb: tuple[int, int, int]

Alias for field number 6

left_center: tuple[int, int]

Alias for field number 7

right_center: tuple[int, int]

Alias for field number 8

left_x: ndarray

Alias for field number 9

left_y: ndarray

Alias for field number 10

right_x: ndarray

Alias for field number 11

right_y: ndarray

Alias for field number 12

classmethod from_json(file, acronym)[source]
Parameters:
  • file (str | Path | PathLike[str])

  • acronym (str)

Return type:

Self

static __new__(_cls, acronym, name, reference, resolution, label, allen_id, allen_rgb, left_center, right_center, left_x, left_y, right_x, right_y)

Create new instance of RegionLabel(acronym, name, reference, resolution, label, allen_id, allen_rgb, left_center, right_center, left_x, left_y, right_x, right_y)

Parameters:
  • acronym (str)

  • name (str)

  • reference (tuple[int, int])

  • resolution (int)

  • label (int)

  • allen_id (int)

  • allen_rgb (tuple[int, int, int])

  • left_center (tuple[int, int])

  • right_center (tuple[int, int])

  • left_x (ndarray)

  • left_y (ndarray)

  • right_x (ndarray)

  • right_y (ndarray)