Skip to content

Conversation

@CodyCBakerPhD
Copy link
Collaborator

@CodyCBakerPhD CodyCBakerPhD commented Nov 3, 2025

Main addition is docs, but relies on some minor utility functions in codebase + CLI invocation

@CodyCBakerPhD CodyCBakerPhD self-assigned this Nov 3, 2025
@codecov
Copy link

codecov bot commented Nov 3, 2025

Codecov Report

❌ Patch coverage is 65.62500% with 22 lines in your changes missing coverage. Please review.
✅ Project coverage is 85.45%. Comparing base (410e6b4) to head (9e73afe).
⚠️ Report is 2 commits behind head on main.

Files with missing lines Patch % Lines
src/nwb2bids/_command_line_interface/_main.py 0.00% 22 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #173      +/-   ##
==========================================
- Coverage   86.60%   85.45%   -1.16%     
==========================================
  Files          32       33       +1     
  Lines        1038     1100      +62     
==========================================
+ Hits          899      940      +41     
- Misses        139      160      +21     
Flag Coverage Δ
unittests 85.45% <65.62%> (-1.16%) ⬇️

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

Files with missing lines Coverage Δ
src/nwb2bids/_converters/_run_config.py 100.00% <100.00%> (ø)
src/nwb2bids/_core/_home.py 100.00% <100.00%> (ø)
src/nwb2bids/testing/__init__.py 100.00% <100.00%> (ø)
src/nwb2bids/testing/_mocks/_tutorials.py 100.00% <100.00%> (ø)
src/nwb2bids/_command_line_interface/_main.py 0.00% <0.00%> (ø)
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

fix: swap from info to tips

fix: add to index

fix: add to index
@CodyCBakerPhD CodyCBakerPhD changed the base branch from main to fix_label_notification November 4, 2025 20:51
@CodyCBakerPhD CodyCBakerPhD changed the title Added tutorials Added tutorials to documentation Nov 5, 2025
@CodyCBakerPhD CodyCBakerPhD marked this pull request as ready for review November 5, 2025 04:06
@CodyCBakerPhD CodyCBakerPhD added documentation Changes only affect the documentation patch Increment the patch version when merged labels Nov 5, 2025
@CodyCBakerPhD CodyCBakerPhD moved this from Todo to In Progress in nwb2bids Roadmap Nov 5, 2025
@CodyCBakerPhD CodyCBakerPhD linked an issue Nov 5, 2025 that may be closed by this pull request
asmacdo
asmacdo previously requested changes Nov 5, 2025
Copy link
Member

@asmacdo asmacdo left a comment

Choose a reason for hiding this comment

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

CLI works, but the python library needs love.

One of the benefits of using sphinx and rst is that we could potentially put these blocks in files, render them in these code blocks with literalinclude, and also execute those files in the tests (or sphinx.ext.doctest, but I havent used that).

@CodyCBakerPhD
Copy link
Collaborator Author

also execute those files in the tests (or sphinx.ext.doctest, but I havent used that).

Good idea, I'll set that up

@CodyCBakerPhD
Copy link
Collaborator Author

@candleindark Ready for review

@yarikoptic
Copy link
Member

yarikoptic commented Dec 3, 2025

From @asmacdo and @yarikoptic: add a note with LINK to BIDS discussion about ideal naming of session/subjects

Did either of you have that link handy?

by now, at least I, already forgot what we talked about ;-) was that zoom session recorded?

I only remember that I recommended, as part of sanitization to remove sub, subject, mouse, etc common prefix if present across all subjects, and the same across sessions. Altogether -- the rule could be

*remove common prefix from labels for multiple files provided since files names should tell what is different, and not really encode metadata, see Filesystem structure & Filenames richness versus distinctness"

but for that we need to operate with multiple files to start with and/or have it "discovered" and then recorded for the dandiset to follow. Altogether also would be good to point to BIDS: Common Principles: Filesystem structure


.. code-block:: bash

cd ~/.nwb2bids/tutorials/ephys_tutorial_file
Copy link
Member

Choose a reason for hiding this comment

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

it might be nice to inlcude the tutorial command to populate each of these. For those who dont mind the hardcoded path in home, these cds make perfect sense, but I used -o so i could put this in /tmp--, and I kept using ephys_tutorial_dataset. Obviously user error, but just wanted you to be aware of that hole to step in :)

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

As per Yariks suggestion these have been moved to the top as pre-commands

After thinking on having only one command vs. two (separate for single-file vs. dataset) I think it is nice to have different scopes (and different tutorials) that are able to focus on different aspects (more detailed file contents vs. broader dataset-level effects)

@CodyCBakerPhD
Copy link
Collaborator Author

*remove common prefix from labels for multiple files provided since files names should tell what is different, and not really encode metadata, see Filesystem structure & Filenames richness versus distinctness"

but for that we need to operate with multiple files to start with and/or have it "discovered" and then recorded for the dandiset to follow. Altogether also would be good to point to BIDS: Common Principles: Filesystem structure

Those sound like the links we want, thanks

Copy link
Member

@yarikoptic yarikoptic left a comment

Choose a reason for hiding this comment

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

move out data preparation

@CodyCBakerPhD
Copy link
Collaborator Author

Added note with links about naming practices, separated generation sections as preambles, and debugged the issue with part 4 and 6

@CodyCBakerPhD
Copy link
Collaborator Author

@asmacdo Ready for eyes again

A quick way to verify output is produced is to just run pytest docs and then go to ~/nwb2bids_tutorials and look at all the bids_dataset_{x} directories corresponding to each case

Copy link
Member

@yarikoptic yarikoptic left a comment

Choose a reason for hiding this comment

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

but let's still move generation of nwb files into Prerequisites section which would cover installation and that data generation

@CodyCBakerPhD
Copy link
Collaborator Author

@asmacdo Drat, you also need to approve since you had previously requested blocking changes 😆

@asmacdo asmacdo dismissed their stale review December 4, 2025 20:13

no need to block if approved

@CodyCBakerPhD CodyCBakerPhD merged commit b398725 into main Dec 5, 2025
25 checks passed
@CodyCBakerPhD CodyCBakerPhD deleted the add_tutorial branch December 5, 2025 17:32
@github-project-automation github-project-automation bot moved this from In Progress to Done in nwb2bids Roadmap Dec 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Changes only affect the documentation patch Increment the patch version when merged

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

Add tutorial with mock data

4 participants