-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use NWBInspector when testing livescript tutorials #618
base: master
Are you sure you want to change the base?
Conversation
- Add note about why dimension of SpatialSeries data is transposed wrt the type specification - Fix typos
- Add explanation of why arrays are transposed relative to the type documentation - Fix dimension order of AbstractFeatureSeries
position_data = [linspace(0, 10, 50); linspace(0, 8, 50)]; % 2 x nT array | ||
%% | ||
% In <https://neurodatawithoutborders.github.io/matnwb/doc/+types/+core/SpatialSeries.html | ||
% |SpatialSeries|> data, the first dimension is always time (in seconds), the | ||
% second dimension represents the x, y position. <https://neurodatawithoutborders.github.io/matnwb/doc/+types/+core/SpatialSeries.html | ||
% second dimension represents the x, y position. However, as described in the | ||
% <https://neurodatawithoutborders.github.io/matnwb/tutorials/html/dimensionMapNoDataPipes.html | ||
% dimensionMapNoDataPipes> tutorial, when a MATLAB array is exported to HDF5, | ||
% the array is transposed. Therefore, in order to correctly export the data, in | ||
% MATLAB the last dimension of an array should be time. <https://neurodatawithoutborders.github.io/matnwb/doc/+types/+core/SpatialSeries.html |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bendichter Can you confirm that this change to the text makes this section more consistent?
% Image data can be stored either in the HDF5 file or as an external image file. | ||
% For this tutorial, we will use fake image data with shape of |('RGB', 'y', 'x', | ||
% 'time') = (200, 50, 50, 3)|. As in all <https://neurodatawithoutborders.github.io/matnwb/doc/+types/+core/TimeSeries.html | ||
% For this tutorial, we will use fake image data with shape of |('time', 'x', | ||
% 'y', 'RGB') = (200, 50, 50, 3)|. As in all <https://neurodatawithoutborders.github.io/matnwb/doc/+types/+core/TimeSeries.html | ||
% |*TimeSeries*|>, the first dimension is time. The second and third dimensions | ||
% represent x and y. The fourth dimension represents the RGB value (length of | ||
% 3) for color images. | ||
% 3) for color images. *Please note*: As described in the <https://neurodatawithoutborders.github.io/matnwb/tutorials/html/dimensionMapNoDataPipes.html | ||
% dimensionMapNoDataPipes> tutorial, when a MATLAB array is exported to HDF5, | ||
% the array is transposed. Therefore, in order to correctly export the data, we | ||
% will need to create a transposed array, where the dimensions are in reverse | ||
% order compared to the type specification. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bendichter Same here
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #618 +/- ##
==========================================
+ Coverage 90.80% 90.84% +0.04%
==========================================
Files 107 107
Lines 4774 4774
==========================================
+ Hits 4335 4337 +2
+ Misses 439 437 -2 ☔ View full report in Codecov by Sentry. |
- Simplifies the reading of nwb files using pynwb in TutorialTest
Fix #484
Motivation
More robust testing of NWB files created by tutorials
Checklist
fix #XX
whereXX
is the issue number?