From ca9286c8a648cabd55081e42091035acd8791305 Mon Sep 17 00:00:00 2001 From: Anton Schwaighofer Date: Tue, 19 Jul 2022 14:17:31 +0100 Subject: [PATCH] BUG: Regex for fastMRI matches more URLs than desired (#762) --- InnerEye/Scripts/prepare_fastmri.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/InnerEye/Scripts/prepare_fastmri.py b/InnerEye/Scripts/prepare_fastmri.py index 6f6d2910..95f1594e 100644 --- a/InnerEye/Scripts/prepare_fastmri.py +++ b/InnerEye/Scripts/prepare_fastmri.py @@ -333,7 +333,7 @@ def extract_access_tokens(text: str) -> Dict[str, str]: :return: """ result: Dict[str, str] = {} - for match in re.finditer(r'(https://fastmri-dataset.s3.amazonaws.com/)([._a-zA-Z0-9]+)(\?[a-zA-Z0-9=&%]+)', text): + for match in re.finditer(r'(https://fastmri-dataset\.s3\.amazonaws\.com/)([._a-zA-Z0-9]+)(\?[a-zA-Z0-9=&%]+)', text): file = match.group(2) token = match.group(3) if file in result: