navis 1.4.0
  • Install
  • Quickstart
  • Tutorials
  • API
  • Changelog
  • Github
  • Ecosystem
  • Site
    • Page
        • navis.MeshNeuron
          • MeshNeuron
            • MeshNeuron.__init__()

    navis.MeshNeuron¶

    class navis.MeshNeuron(x, units=None, process=True, validate=False, **metadata)[source]¶

    Neuron represented as mesh with vertices and faces.

    Parameters:
    • x (Union[DataFrame, BufferedIOBase, str, TreeNeuron, DiGraph]) –

      Data to construct neuron from:
      • any object that has .vertices and .faces properties (e.g. a trimesh.Trimesh)

      • a tuple (vertices, faces)

      • a dictionary {"vertices": (N, 3), "faces": (M, 3)}

      • filepath to a file that can be read by trimesh.load

      • None will initialize an empty MeshNeuron

      • skeletor.Skeleton will use the mesh and the skeleton (including the vertex to node map)

    • units (str | pint.Units | pint.Quantity) – Units for coordinates. Defaults to None (dimensionless). Strings must be parsable by pint: e.g. “nm”, “um”, “micrometer” or “8 nanometers”.

    • process (bool) – If True (default and highly recommended), will remove NaN and infinite values, and merge duplicate vertices.

    • validate (bool) – If True, will try to fix some common problems with meshes. See navis.fix_mesh for details.

    • **metadata – Any additional data to attach to neuron.

    Initialize Mesh Neuron.

    __init__(x, units=None, process=True, validate=False, **metadata)[source]¶

    Initialize Mesh Neuron.

    Methods

    __init__(x[, units, process, validate])

    Initialize Mesh Neuron.

    convert_units(to[, inplace])

    Convert coordinates to different unit.

    copy()

    Return a copy of the neuron.

    map_units(units[, on_error])

    Convert units to match neuron space.

    memory_usage([deep, estimate])

    Return estimated memory usage of this neuron.

    plot2d(**kwargs)

    Plot neuron using navis.plot2d().

    plot3d(**kwargs)

    Plot neuron using navis.plot3d().

    skeletonize([method, heal, inv_dist])

    Skeletonize mesh.

    snap(locs[, to])

    Snap xyz location(s) to closest vertex or synapse.

    summary([add_props])

    Get a summary of this neuron.

    validate([inplace])

    Use trimesh to try and fix some common mesh issues.

    Attributes

    CORE_DATA

    Core data table(s) used to calculate hash

    EQ_ATTRIBUTES

    Attributes to be used when comparing two neurons.

    SUMMARY_PROPS

    Attributes used for neuron summary

    TEMP_ATTR

    Temporary attributes that need clearing when neuron data changes

    bbox

    Bounding box (includes connectors).

    connectors

    Connector table.

    core_md5

    MD5 checksum of core data.

    datatables

    Names of all DataFrames attached to this neuron.

    extents

    Extents of neuron in x/y/z direction (includes connectors).

    faces

    Faces making up the neuron.

    graph

    Networkx Graph representation of the vertex connectivity.

    id

    Hashable ID.

    igraph

    iGraph representation of the vertex connectivity.

    is_isometric

    Test if neuron is isometric.

    is_locked

    Test if neuron is locked.

    is_stale

    Test if temporary attributes might be outdated.

    label

    Label (e.g.

    name

    Neuron name.

    postsynapses

    Table with postsynapses.

    presynapses

    Table with presynapses.

    sampling_resolution

    Average distance between vertices.

    skeleton

    Skeleton representation of this neuron.

    trimesh

    Trimesh representation of the neuron.

    type

    Neuron type.

    units

    Units for coordinate space.

    units_xyz

    Units for coordinate space.

    vertices

    Vertices making up the neuron.

    volume

    Volume of the neuron.

    soma

    Back to top

    Source

    © Copyright 2018, Philipp Schlegel.
    Created using Sphinx 5.3.0.