-
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
[Bug]: convertTrials Tutorial uses Out of Date Syntax #515
Comments
I cannot reproduce. Can you please make sure you MatNWB is up-to-date? If you used |
If that doesn't work, you can delete MatNWB and download it again from here. |
Hi there,
After deleting Matnwb and downloading it again, the mentioned problem has been resolved.
Thank you.
But I got another error message when I tried to run the script "MatNWB\tutorials\convertTrials.m."
code at line 351:
trials_epoch = types.core.TimeIntervals(...
'start_time', types.hdmf_common.VectorData('data', data.trialStartTimes,...
'description', 'Start time of epoch, in seconds.'),...
'colnames', [data.trialTypeStr; data.trialPropertiesHash.keyNames .';...
{'start_time'; 'stop_time'; 'acquisition'; 'timeseries'}],...
'description', 'trial data and properties', ...
'id', types.hdmf_common.ElementIdentifiers('data', data.trialIds),...
'timeseries', types.hdmf_common.VectorData('description', 'Index into timeseries Data'),...
'timeseries_index', types.hdmf_common.VectorIndex(...
'description', 'Index into Timeseries VectorData',...
'target', types.untyped.ObjectView('/intervals/trials/timeseries')));
Error Message:
Error using assert
Value of type `types.hdmf_common.VectorData` cannot be converted to type `types.core.TimeSeriesReferenceVectorData`.
Error in types.util.correctType (line 60)
assert(isa(val, type), ...
Error in types.util.checkDtype (line 96)
correctedValue = types.util.correctType(val, type);
Error in types.core.TimeIntervals/validate_timeseries (line 82)
val = types.util.checkDtype('timeseries', 'types.core.TimeSeriesReferenceVectorData', val);
Error in types.core.TimeIntervals/set.timeseries (line 62)
obj.timeseries = obj.validate_timeseries(val);
Error in types.core.TimeIntervals (line 39)
obj.timeseries = p.Results.timeseries;
Error in convertTrials4jia (line 407)
trials_epoch = types.core.TimeIntervals(...
…________________________________
From: Ben Dichter ***@***.***>
Sent: Wednesday, July 19, 2023 2:54 PM
To: NeurodataWithoutBorders/matnwb ***@***.***>
Cc: Chen, Jian ***@***.***>; Author ***@***.***>
Subject: Re: [NeurodataWithoutBorders/matnwb] [Bug]: types.core.Units (Issue #515)
***CAUTION:*** This email is not from a BCM Source. Only click links or open attachments you know are safe.
________________________________
If that doesn't work, you can delete MatNWB and download it again from here.
—
Reply to this email directly, view it on GitHub<https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_NeurodataWithoutBorders_matnwb_issues_515-23issuecomment-2D1642669789&d=DwMCaQ&c=ZQs-KZ8oxEw0p81sqgiaRA&r=9Gl8TqypehHm7acAeymJOA&m=uZYmThSPMyqB_VkqqTDcYyajN0KuMwuSIJAcQ3W7anfCFRXOzNpAL7U-ZjHlUydb&s=-8pEDRIWM8tXwrdrSeKpnsqXGqsMNTsSX2k27Udy5Hw&e=>, or unsubscribe<https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_ACQUAUTWVEIV5SMNJKNW3CTXRA3NRANCNFSM6AAAAAA2QJULUE&d=DwMCaQ&c=ZQs-KZ8oxEw0p81sqgiaRA&r=9Gl8TqypehHm7acAeymJOA&m=uZYmThSPMyqB_VkqqTDcYyajN0KuMwuSIJAcQ3W7anfCFRXOzNpAL7U-ZjHlUydb&s=6OAtznhWx-qTpNBbwOiH1phuPAAMBjteOE9w4w5SL-U&e=>.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
yeah, this looks like outdated code |
So do you have an updated convertTrials.m? |
The code was probably added before validation changes to |
Co-authored-by: Ben Dichter <[email protected]>
What happened?
When running matnwb(2.6.0), I got an error message. I am wondering that is due to a bug with matnwb. Or Could you please let me know how to fix it?
Thank you in advance for your time and help.
Steps to Reproduce
Error Message
Operating System
Windows
Matlab Version
Matlab R2023a
Code of Conduct
The text was updated successfully, but these errors were encountered: