How to use the nixio.LinkType.Indexed function in nixio

To help you get started, we’ve selected a few nixio examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github NeuralEnsemble / python-neo / neo / io / nixio.py View on Github external
nixgroup.multi_tags.append(nixmt)

        if waveforms is not None:
            wfdata = list(wf.magnitude for wf in
                          list(wfgroup for wfgroup in
                               spiketrain.waveforms))
            wfunits = units_to_string(spiketrain.waveforms.units)
            wfda = nixblock.create_data_array(
                "{}.waveforms".format(nix_name), "neo.waveforms",
                data=wfdata
            )
            wfda.unit = wfunits
            wfda.metadata = nixmt.metadata.create_section(
                wfda.name, "neo.waveforms.metadata"
            )
            nixmt.create_feature(wfda, nix.LinkType.Indexed)
            # TODO: Move time dimension first for PR #457
            # https://github.com/NeuralEnsemble/python-neo/pull/457
            wfda.append_set_dimension()
            wfda.append_set_dimension()
            wftime = wfda.append_sampled_dimension(
                spiketrain.sampling_period.magnitude.item()
            )
            wftime.unit = units_to_string(spiketrain.sampling_period.units)
            wftime.label = "time"

            if spiketrain.left_sweep is not None:
                self._write_property(wfda.metadata, "left_sweep",
                                     spiketrain.left_sweep)

nixio

Python reimplementation of NIXIO (http://g-node.github.io/nix/)

BSD-2-Clause
Latest version published 18 days ago

Package Health Score

65 / 100
Full package analysis