cpp-lln-lab / cpp_bids Goto Github PK
View Code? Open in Web Editor NEWa set of matlab / octave function to create BIDS comptible folder structure and filenames
Home Page: https://cpp-bids.readthedocs.io/en/dev/index.html
License: MIT License
a set of matlab / octave function to create BIDS comptible folder structure and filenames
Home Page: https://cpp-bids.readthedocs.io/en/dev/index.html
License: MIT License
Binder example
I always forget, and was looking in README for usage of functions. first we set values in our experiment setParams.m
and then run CPP_BIDS
functions (e.g. userInput
and createFilename
). createFilename will set fields IF it's not set previously. Right? So my cfg.fields
should be filled before I call BIDS functions.
Would you like to add one sentence somewhere that first the user should run their getParams and set all the fields. Then empty fields would be filled by the default values in CPP_BIDS functions.. I can add it as well, if you can point out where that info should be? e.g. in usage notebook?
is it possible to create two different output file? e.g. .tsv file for stimulus
and .tsv file for tapping
it might be my issue, will check but now the code is creating eyetracker
folder in addition to beh folder.
It calls createFilename(expParameters,cfg)
I'm proposing to be consistent with the rest of the scripts the following order change:
createFilename(cfg,expParameters)
can it be deleted from the outputs?
for example I forgot to update the version.txt in the last release
@Remi-Gau and @marcobarilari this is still open issue right? I see the .tsv
file is only producing 1-line instead of saving the full output structure. I see it's because of how readAndFilterLogfile
is creating the data structure and how tsvwrite
function reads, basically the dimensions do not match. the output readandFilterLogfile
is size = 1
, and tsvwrite
goes through that size
option.
The test_readAndFilter
does not fail because it does not look at how .tsv
file is saved - which is only saving the 1-line of the output.
Originally posted by @CerenB in #104 (comment)
Originally posted by @Remi-Gau in #101 (comment)
At first let's not worry about the anonymization issues and let's keep the dates as they are.
https://bids-specification.readthedocs.io/en/stable/03-modality-agnostic-files.html#scans-file
The BIDS specs only have onset and duration as required so make sure that saveEvents skips events with the wrong values.
Atm, when the bids added with
addpath(fullfile(pth, 'lib', 'CPP_BIDS', 'src'));
due to the subfunc folder is not inside src, would it be an issue? Will check it now. (after resolving the following error)
Need to make sure they are purely alphanumeric eventually with camelCase.
Warning: Missing some target data for this event.
> In saveEventsFile>checkExtracolumns (line 240)
In saveEventsFile>checklLogFile (line 166)
In saveEventsFile (line 84)
In fMRIMainExperiment (line 229)
onset: 199.7325
trial_type: 'response'
duration: 0
key_name: 'space'
pressed: 1
fileID: []
extraColumns: []
target: NaN
sub-001_ses-001_task-RhythmCategFT_run-001_events_date-202007272044.tsv
previously it was:sub-001_ses-001_task-RhythmCategFT_run-001_events_date-20200727_2044.tsv
I think at the moment we only accept pc
but it would make sense to have beh
as well I think. Feel free to open an issue so we remember to do that.
Originally posted by @Remi-Gau in #123 (comment)
I'm opening two logfiles
(_event
and _stim
) consecuitively. When I only open the logfile (_event
) with extraColumn
, createDataDictionary
nicely creates a json
file with all the extra columns.
Then when I open the following, _stim
, that json
file for the logfile / _event
got back to its default settings without the extraColumns
.
Any idea why is it happening?
% create logfile with extra columns to save - BIDS
logFile.extraColumns = cfg.extraColumns;
[logFile] = saveEventsFile('open', cfg, logFile); %dummy initialise
% set the real length of columns
logFile(1).extraColumns.LHL24.length = 12;
logFile(1).extraColumns.PE4.length = 12;
% actual inititalization
logFile = saveEventsFile('open', cfg, logFile);
% create response file - used for counting button press
responseFile.extraColumns = cfg.responseExtraColumns;
responseFile = saveEventsFile('open_stim', cfg, responseFile);
Error in CI on checking the markdown
https://travis-ci.com/github/cpp-lln-lab/CPP_BIDS/jobs/430652513
$ npm install `cat npm-requirements.txt`
Unhandled rejection Error: EACCES: permission denied, mkdir '/home/travis/.npm/_cacache/content-v2/sha512/a4/f5'
Unhandled rejection Error: EACCES: permission denied, mkdir '/home/travis/.npm/_cacache/content-v2/sha512/33/9a'
Unhandled rejection Error: EACCES: permission denied, mkdir '/home/travis/.npm/_cacache/content-v2/sha512/ce/b2'
Unhandled rejection Error: EACCES: permission denied, mkdir '/home/travis/.npm/_cacache/content-v2/sha512/d2/66'
Unhandled rejection Error: EACCES: permission denied, mkdir '/home/travis/.npm/_cacache/content-v2/sha512/a2/ce'
npm ERR! cb() never called!
npm ERR! This is an error with npm itself. Please report this error at:
npm ERR! <https://npm.community>
npm ERR! A complete log of this run can be found in:
npm ERR! /home/travis/.npm/_logs/2020-11-08T10_35_52_601Z-debug.log
The command "npm install `cat npm-requirements.txt`" failed and exited with 1 during .
Originally posted by @Remi-Gau in #120 (comment)
if askGrpSess(1)
subjectGrp = lower(input('Enter subject group (leave empty if none): ', 's'));
end
At the moment, outside of debug mode, there's no subjectGrp
assignment if askGrpSess =0
. So the script crashes there.
is it compulsory for BIDS? If yes, then nothing can be done, I see. But if it's not having small letters all the way through does not help to read variables in logfile.
@all-contributors please add @Remi-Gau code, design, doc
Some of the rules on the requirements of the stim
files have now been enforced in the new version of the bids validator.
https://github.com/bids-standard/bids-validator/releases/tag/v1.5.6
After I bump up version of CPP_BIDS I will try to have a look at that and let you know what it changes.
tagging @CerenB as you might want to follow up on that. ๐
in createFilename.m
at the current state, in userInput
function I can leave the group part empty but then in createFilename gives error that
Reference to non-existent field 'subjectGrp'
in createFilename.m
In SaveEventFile.m
, I cannot save cell array. Is there a solution or suggestion for this?
Error using fprintf
Function is not defined for 'cell' inputs.
Error in saveEventsFile (line 86)
fprintf(logFile(1).eventLogFile, '%f\t', data);
Error in tapMainExperiment (line 102)
saveEventsFile('save', expParam, currSeq, ...
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.