tasks.circuit

Luigi tasks for circuit and atlas processings.

Classes

CreateAtlasLayerAnnotations

Create the annotation file for layers from an atlas.

CreateAtlasPlanes

Create plane cuts of an atlas.

CreateBoundaryMask

Create mask at the boundary of the region to prevent placing somata too close to boundary.

BuildCircuit

Generate cell positions and me-types from atlas, compositions and taxonomy.

SliceCircuit

Create a smaller circuit file for subsampling.

Module Contents

class CreateAtlasLayerAnnotations(*args, **kwargs)

Bases: luigi_tools.task.WorkflowTask

Create the annotation file for layers from an atlas.

layer_annotations_path

Path to save layer annotations constructed from atlas.

Type:

str

Default value:

layer_annotation.nrrd

class CreateAtlasPlanes(*args, **kwargs)

Bases: luigi_tools.task.WorkflowTask

Create plane cuts of an atlas.

plane_type

Type of planes creation algorithm. It can take the value ‘centerline’, so the center line is computed between first_bound and last_bound with internal algorithm (from atlas-analysis package), or the value ‘aligned’ (warning: experimental) so center line is a straight line, along the centerline_axis.

Type:

str

Choices:

{centerline_curved, centerline_straight, aligned}

Default value:

aligned

plane_count

Number of planes to create slices of atlas.

Type:

int

Permitted values:

int in [1, 1000000000.0)

Default value:

10

slice_thickness

Thickness of slices (in micrometer).

Type:

float

Default value:

100

centerline_first_bound

(only for plane_type == centerline) Location of first bound for centerline (in voxcell index).

Type:

list(int)

centerline_last_bound

(only for plane_type == centerline) Location of last bound for centerline (in voxcell index).

Type:

list(int)

centerline_axis

(only for plane_type = aligned) Axis along which to create planes.

Type:

str

Default value:

0

atlas_planes_path

Path to save atlas planes.

Type:

str

Default value:

atlas_planes

class CreateBoundaryMask(*args, **kwargs)

Bases: luigi_tools.task.WorkflowTask

Create mask at the boundary of the region to prevent placing somata too close to boundary.

boundary_thickness

Thickness to create a mask to prevent placing cells near boundary, in units of voxel size.

Type:

int

Default value:

0

mask_path
class BuildCircuit(*args, **kwargs)

Bases: luigi_tools.task.WorkflowTask

Generate cell positions and me-types from atlas, compositions and taxonomy.

density_factor

The density of positions generated from the atlas.

Type:

float

Permitted values:

float in (0, 1]

Default value:

0.5

seed

Pseudo-random generator seed.

Type:

int

Default value:

42

mtype_taxonomy_file

Filename of taxonomy file to provide to BrainBuilder

Type:

str

Default value:

mtype_taxonomy.tsv

class SliceCircuit(*args, **kwargs)

Bases: luigi_tools.task.WorkflowTask

Create a smaller circuit file for subsampling.

mtypes

List of mtypes to consider.

Type:

list

sliced_circuit_path

Path to save sliced circuit.

Type:

str

Default value:

sliced_circuit_somata.h5

n_cells

Number of cells per mtype to consider.

Type:

int

Default value:

10