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

Let ends_with accept a series of pattern to check #199

Open
Remi-Gau opened this issue Apr 16, 2021 · 1 comment
Open

Let ends_with accept a series of pattern to check #199

Remi-Gau opened this issue Apr 16, 2021 · 1 comment

Comments

@Remi-Gau
Copy link
Collaborator

Will it be a more complexity/performance issue to make it also accept cellstr for pat?

Originally posted by @nbeliy in #172 (comment)

@nbeliy
Copy link
Collaborator

nbeliy commented Apr 19, 2021

I found that in matlab the string operations are sometimes more effectively treated by regexp than by dedicated functions.
Probably because regexp is compiled.
It could be beneficial to create a set of low level BIDS string operations and compile them:

  • getting modality (string before '/')
  • getting extension (string after first '.')
  • getting suffix (string between last '_' and first '.')
  • splitting entities in pairs key - value

I tried to write some of them (just a trivial string scan) but the performance is on par with regexp

@Remi-Gau Remi-Gau added this to Wish list in General Kanban Sep 20, 2021
@Remi-Gau Remi-Gau removed this from Wish list in General Kanban May 10, 2022
@Remi-Gau Remi-Gau added this to Wish list in General Kanban Dec 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Wish list
Development

No branches or pull requests

2 participants