Skip to content

Conversation

@bendichter
Copy link
Contributor

fix #997

@bendichter bendichter requested a review from h-mayorquin August 12, 2024 16:28
Copy link
Collaborator

@h-mayorquin h-mayorquin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why break the pattern of the other interfaces and functions where the data and metadata are in separate streams? Here we send them both through the columns. How are you thinking about it?

TimeIntervals=dict(
trials=dict(
columns=dict(
start_time=dict(description="start time of the trial"),
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't this overwritten by the schema by default? the description of start_time and stop_time?

"type": "string"
}
},
"required": [
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't description be required as well?]

from pynwb.testing.mock.file import mock_NWBFile

nwbfile = mock_NWBFile()
nwbfile.add_trial_column(name='correct')

Throws an error.

columns=dict(
start_time=dict(description="start time of the trial"),
stop_time=dict(description="stop time of the trial"),
correct=dict(description="correct or not"),
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was expecting that you had to pass the name inside the dictionary as well from reading the schema, but here, the name here is only passed as the dictionary key.

@codecov
Copy link

codecov bot commented Jul 2, 2025

Codecov Report

Attention: Patch coverage is 78.37838% with 8 lines in your changes missing coverage. Please review.

Project coverage is 91.37%. Comparing base (b7ae085) to head (4576bc4).
Report is 298 commits behind head on main.

Files with missing lines Patch % Lines
...conv/datainterfaces/text/timeintervalsinterface.py 75.00% 8 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #999      +/-   ##
==========================================
- Coverage   91.44%   91.37%   -0.08%     
==========================================
  Files         127      127              
  Lines        7525     7556      +31     
==========================================
+ Hits         6881     6904      +23     
- Misses        644      652       +8     
Flag Coverage Δ
unittests 91.37% <78.37%> (-0.08%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
src/neuroconv/datainterfaces/__init__.py 100.00% <100.00%> (ø)
...tainterfaces/text/csv/csvtimeintervalsinterface.py 100.00% <100.00%> (ø)
...terfaces/text/excel/exceltimeintervalsinterface.py 100.00% <100.00%> (ø)
...conv/datainterfaces/text/timeintervalsinterface.py 86.66% <75.00%> (-6.67%) ⬇️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature]: add trials to metadata

3 participants