Open ageorgou opened 4 years ago
This is still far from done but it's a start! It may be that subclasses for RoiReader
are not the way to go (instead, we could create the mappings and specify behaviour through functions or other classes -- composition rather than inheritance). Since there is no immediate prospect of further LabView versions, however, we might as well not overcomplicate this right now.
The main remaining changes are:
RoiReaderv300
RoiReader
that takes a ROI number and an NWBFile
(or perhaps our own NwbFile
) and creates/returns the imaging plane corresponding to the acquisition for that ROI. For older versions, this should give the ImagingPlane
created for the corresponding Z-plane. For the latest version, and only if variable shapes are enabled, it should create a new ImagingPlane
based on that ROI's coordinates and resolution (thinking about this, maybe it should take a channel too, so we don't duplicate between Red and Green ROIs?) This method should be called from read_functional_data
, when determining the imaging plane for the acquisition named ROI_NNN_Red/Green
.Merging #74 (8115f8f) into master (358c551) will increase coverage by
1.48%
. The diff coverage is85.59%
.
@@ Coverage Diff @@
## master #74 +/- ##
==========================================
+ Coverage 59.32% 60.80% +1.48%
==========================================
Files 17 19 +2
Lines 1866 2008 +142
Branches 275 292 +17
==========================================
+ Hits 1107 1221 +114
- Misses 716 738 +22
- Partials 43 49 +6
Impacted Files | Coverage Δ | |
---|---|---|
src/silverlabnwb/signature.py | 56.73% <ø> (ø) |
|
tests/test_labview_import.py | 75.71% <50.00%> (-0.76%) |
:arrow_down: |
src/silverlabnwb/rois.py | 78.31% <78.31%> (ø) |
|
src/silverlabnwb/nwb_file.py | 90.21% <82.43%> (-1.93%) |
:arrow_down: |
src/silverlabnwb/header.py | 88.96% <87.50%> (+0.32%) |
:arrow_up: |
src/silverlabnwb/metadata.py | 89.04% <100.00%> (ø) |
|
src/silverlabnwb/timings.py | 98.24% <100.00%> (+4.39%) |
:arrow_up: |
tests/test_header.py | 100.00% <100.00%> (ø) |
|
tests/test_rois.py | 100.00% <100.00%> (ø) |
|
tests/test_timings.py | 100.00% <100.00%> (ø) |
|
... and 2 more |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact)
,ø = not affected
,? = missing data
Powered by Codecov. Last update 358c551...8115f8f. Read the comment docs.
Latest changes look good. Making a note to check that everything works with variable-shape ROIs as it's not yet tested on Travis.
I suggest we merge this (without creating a new release yet). Have created #80 and #81 for the remaining issues/questions.
Will fix #36.