Skip to content
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

Running into errors when running "session" #8

Open
crewl2 opened this issue Jun 6, 2023 · 10 comments
Open

Running into errors when running "session" #8

crewl2 opened this issue Jun 6, 2023 · 10 comments
Assignees

Comments

@crewl2
Copy link

crewl2 commented Jun 6, 2023

I'm running into errors trying to run the session command. I need some guidance to learn how to use this matlab package. Any help would be appreciated.

@crewl2
Copy link
Author

crewl2 commented Aug 15, 2023

I'm frustrated that no one has helped me with this. I cannot get it to run, and I have hundreds of binary files that I would like to read and open in Matlab. Please assist! Thank you..

@medengineer
Copy link
Member

Hi,

Can you please post the Matlab commands you are using to load your files using the latest v1.3.0 of matlab-tools along with any error output?

Thanks!

@crewl2
Copy link
Author

crewl2 commented Aug 15, 2023

Thank you so much, I've been trying to figure this out on my own, but I just don't have enough expertise in this area to work through it.

directory = '/Volumes/SHUGGIE/2023-08-14_14-56-28_TouchScreenTTLTest' % for example

session = Session(directory)

session = Session(directory)
[DEBUG] Searching directory: /Volumes/SHUGGIE/2023-08-14_14-56-28_TouchScreenTTLTest
[DEBUG] Found recording format: Binary
Intermediate brace '{}' indexing produced a comma-separated list with 0 values, but it must produce a single value when followed
by subsequent indexing operations.

Error in BinaryRecording/loadSyncMessages (line 211)
node_name = strjoin({strjoin(message(4:(idx-4)),'_'),message{idx-3}(2:end-1)},'-');

Error in BinaryRecording/loadContinuous (line 50)
syncMessages = self.loadSyncMessages();

Error in BinaryRecording (line 40)
self = self.loadContinuous();

Error in BinaryRecording.detectRecordings (line 254)
recordings{end+1} = BinaryRecording(recordingDirectories{recIdx}, expIdx, recIdx);

Error in RecordNode/detectRecordings (line 95)
self.recordings = BinaryRecording.detectRecordings(self.directory);

Error in RecordNode (line 71)
self.detectRecordings();

Error in Session/detectRecordNodes (line 70)
self.recordNodes{end+1} = RecordNode(paths{i});

Error in Session (line 61)
self.detectRecordNodes();

Related documentation

@medengineer
Copy link
Member

The error message suggests you are using an older version of matlab-tools that uses the loadSyncMessages() function which is causing the crash.

The latest version 1.3.0 released ~2 months ago no longer uses this function. Can you confirm you are using the latest version on the Releases page?

@crewl2
Copy link
Author

crewl2 commented Aug 17, 2023

I updated matlab-tools and I am now getting this error:

File not found: /Volumes/SHUGGIE/2023-08-14_14-56-28_TouchScreenTTLTest/Record Node
102/experiment1/recording1/continuous/Rhythm_FPGA-100.0/sample_numbers.npy

Error in readNPY (line 9)
[shape, dataType, fortranOrder, littleEndian, totalHeaderLength, ~] = readNPYheader(filename);

Error in BinaryRecording/loadContinuous (line 73)
stream.sampleNumbers = readNPY(fullfile(directory, 'sample_numbers.npy'));

Error in BinaryRecording (line 40)
self = self.loadContinuous();

Error in BinaryRecording.detectRecordings (line 240)
recordings{end+1} = BinaryRecording(recordingDirectories{recIdx}, expIdx, recIdx);

Error in RecordNode/detectRecordings (line 95)
self.recordings = BinaryRecording.detectRecordings(self.directory);

Error in RecordNode (line 71)
self.detectRecordings();

Error in Session/detectRecordNodes (line 70)
self.recordNodes{end+1} = RecordNode(paths{i});

Error in Session (line 61)
self.detectRecordNodes();

@crewl2
Copy link
Author

crewl2 commented Aug 17, 2023

Which is one of the original errors I was getting. I'm not sure where sample_numbers.npy is supposed to be located as I don't have that in my files.

@medengineer
Copy link
Member

Missing sample_numbers.npy suggests your recordings are from an older version of OpenEphys GUI.

If you can post here the GUI version number of your recordings, (it can be found in the settings.xml file), I can apply the patch to the proper version of matlab tools and you will be able to load your recordings.

@crewl2
Copy link
Author

crewl2 commented Aug 18, 2023

0.5.4

Is this correct?

@medengineer
Copy link
Member

Yes, version 0.5.4 did not have sample_numbers.npy yet.

Can you try loading your session using the version linked below and post any error output if it still doesn't work?

https://www.dropbox.com/scl/fi/z32aw9x8dasnt8jdat6js/matlab-tools-0.5.4.zip?rlkey=rkkz08rpyes61ji08nqp2m1ks&dl=0

@medengineer
Copy link
Member

medengineer commented Aug 31, 2023 via email

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

No branches or pull requests

2 participants