Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
f766a74
Add dataset/buildDataset symmetry tests
claude Mar 16, 2026
f4a838f
Fix depends_on AttributeError and add symmetry CI job
claude Mar 16, 2026
943752f
Rewrite symmetry CI as full MATLAB<->Python pipeline
claude Mar 16, 2026
337ea0a
Fix symmetry tests to match MATLAB artifact format
claude Mar 16, 2026
cfb1028
Fix superclasses normalization — DAQ systems now reconstruct from MAT…
claude Mar 16, 2026
2949421
Use DID-python API in DatabaseDriver.find(); fix session summary symm…
claude Mar 16, 2026
929f50f
Fix epoch discovery and session summary for MATLAB-created sessions
claude Mar 16, 2026
ac79759
Add NDR-matlab to NDR-python porting instructions
claude Mar 16, 2026
58b61ea
Merge origin/main into feature branch
claude Mar 16, 2026
b3e4f5e
Fix black formatting in symmetry test files
claude Mar 16, 2026
cee14ff
Replace SpikeInterface with vlt.hardware.intan for Intan RHD reading
claude Mar 17, 2026
63d96f0
Use ndr.format.intan for Intan header reading and data file reading
claude Mar 17, 2026
bd07ec4
Add Pythonic aliases: Document, Query, DirSession, Dataset
claude Mar 17, 2026
6565e00
Remove duplicate symmetry job from ci.yml
claude Mar 17, 2026
656d239
Fix black formatting in test_daq.py
claude Mar 17, 2026
1056a71
Fix EpochProbeMap import to use correct class name ndi_epoch_epochpro…
claude Mar 17, 2026
6b2142a
Store MATLAB-compatible session_creator name in dataset metadata
claude Mar 17, 2026
74e8f1b
Replace hardcoded class-name mappings with mechanical conversion
claude Mar 17, 2026
b638030
Update calculator name assertions to expect MATLAB-style names
claude Mar 17, 2026
3ad2ef8
Fix dataset summary to include jsonDocuments in files list
claude Mar 17, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
810 changes: 810 additions & 0 deletions docs/developer_notes/NDR_PORTING_INSTRUCTIONS.md

Large diffs are not rendered by default.

12 changes: 6 additions & 6 deletions examples/integration_demo.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,12 @@
This is the workflow the cofounder is building toward!
"""

import numpy as np
import os
import tempfile

# Our NDI core (Phase 2 implementation)
from ndi import Document, Query, Ido
import numpy as np

from ndi import Document, Ido, Query
from ndi.common import timestamp

# Cofounder's compression library
Expand Down Expand Up @@ -52,7 +52,7 @@ def demo_full_workflow():
sample_rate = 30000

# Simulate neural data: noise + spikes
t = np.linspace(0, 1, num_samples)
_t = np.linspace(0, 1, num_samples)
data = np.random.randn(num_samples, num_channels) * 50 # noise

# Add some "spikes"
Expand Down Expand Up @@ -138,7 +138,7 @@ def demo_full_workflow():
q3 = Query('base.name').contains('ephys')

# Combined query
q_combined = q1 & q2 & q3
_q_combined = q1 & q2 & q3

print(f" Query 1: {q1.to_searchstructure()}")
print(f" Query 2: {q2.to_searchstructure()}")
Expand Down Expand Up @@ -225,7 +225,7 @@ def demo_document_features():
doc = doc.setproperties(**{
'base.name': 'neural_recording',
})
print(f"3. Set name via setproperties")
print("3. Set name via setproperties")

# Document equality (by ID)
doc2 = Document(doc.document_properties)
Expand Down
2 changes: 2 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ classifiers = [
requires-python = ">=3.10"
dependencies = [
"did @ git+https://github.com/VH-Lab/DID-python.git@main",
"ndr @ git+https://github.com/VH-lab/NDR-python.git@main",
"vhlab-toolbox-python @ git+https://github.com/VH-Lab/vhlab-toolbox-python.git@main",
"numpy>=1.20.0",
"networkx>=2.6",
"jsonschema>=4.0.0",
Expand Down
5 changes: 4 additions & 1 deletion src/ndi/calculator.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@

from .app import ndi_app
from .app.appdoc import DocExistsAction, ndi_app_appdoc
from .util.classname import ndi_matlab_classname

if TYPE_CHECKING:
from .document import ndi_document
Expand Down Expand Up @@ -59,7 +60,7 @@ def __init__(
path_to_doc_type: Path to the document type schema
"""
# Initialize ndi_app (session + name from class)
name = type(self).__name__
name = ndi_matlab_classname(self)
ndi_app.__init__(self, session=session, name=name)

# Initialize ndi_app_appdoc
Expand Down Expand Up @@ -353,6 +354,8 @@ def search_for_calculator_docs(
# Add dependency constraints
depends_on = parameters.get("depends_on", [])
for dep in depends_on:
if not isinstance(dep, dict):
continue
dep_name = dep.get("name", "")
dep_value = dep.get("value", "")
if dep_value:
Expand Down
3 changes: 2 additions & 1 deletion src/ndi/daq/metadatareader/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
from typing import Any

from ...ido import ndi_ido
from ...util.classname import ndi_matlab_classname


class ndi_daq_metadatareader(ndi_ido):
Expand Down Expand Up @@ -270,7 +271,7 @@ def newdocument(self) -> Any:
doc = ndi_document(
"daq/daqmetadatareader",
**{
"daqmetadatareader.ndi_daqmetadatareader_class": self.__class__.__name__,
"daqmetadatareader.ndi_daqmetadatareader_class": ndi_matlab_classname(self),
"daqmetadatareader.tab_separated_file_parameter": self._tab_separated_file_parameter,
"base.id": self.id,
},
Expand Down
Loading
Loading