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
Rename tasks #774
Comments
hey @mateuszpawlik This relates to a similar question on the BIDS mailing lists: https://groups.google.com/g/bids-discussion/c/HX0LEZZyDSU This also relates to an old issue I opened ages ago but did nothing about to enhance "the file writing" capabilities of pybids: I suspect that more and more people will eventually need such tools and functionalities, so happy to join forces with you to help enhance pybids in that direction. Will tag @tsalo on this one because maybe some of those functions would be better in pybids-light: https://github.com/bids-standard/pybids-light |
While searching for a solution to a slightly different problem I accidentally found the BIDS mailing list today and read your thread there. I also found your pybids issue. These coincidences ;-) My today's problem was to rename tasks while converting to BIDS with BIDScoin. If you're interested, thanks to Marcel Zwiers it's ready to be tested. I think a tool to query and manipulate BIDS data would be useful. Though, I'm not sure if such a functionality should be implemented in pybids. It is not clear to me, what exactly is pybids for and where does it go. The documentation is vague. On the one hand, there is the querying, on the other hand you can review glm models or generate textual reports, but it also executes the BIDS validator. I recently used pybids, also as an exercise for myself, to write a simple BIDS app to discard volumes from the images. This required querying a BIDS dataset to find all functional images and their sidecar json files, and modify them. It wasn't exactly clear how to do it (#773, #771). Due to my databases background, I'd say that BIDS needs kind of a DML. Not necessarily a language but a tool to also manipulate the data with BIDS specification in mind. I'd also have another application for that. For some not yet public studies we'd like to share only specific data (subjects, tasks, modalities, etc.) but still in BIDS. Such a querying tool could nicely export the desired snapshot. BIDS data is rather complex with heterogeneous data sources: directory and file names, json files, and tsv files. I like the idea of loading all that into a database, like pybids does, because it simplifies querying. Modifying the data and writing it back is a different story I think. I'm happy to join the forces and I should have some time resources for that. Excuse me for a long text and going off topic a little bit. |
I think the issue Should this repo get 2nd life as bids-cmdline or smth like that? #6 in bidsutils may also support what @Remi-Gau wrote. |
I have no objection to adding a subcommand to the PyBIDS CLI. This does seem useful, and I'd say it's up to whoever is implementing to decide where it best lives. |
I want to rename the tasks of fmri data based on subject id and old task name. For that, I need to rename the files and the TaskName values in the json files. I thought about writing a more generic BIDS app. Does pybids have any facility for renaming files or should I better use the os.rename?
The text was updated successfully, but these errors were encountered: