OSCR

Comparing deep learning stroke segmentation in NCCT, CTA, and CTP: Accuracy, domain transfer, and temporal sampling effect.

Code ↔ Paper

1 match between paragraphs of the paper and lines of its authors' code, computed by the harvester (lexical-v1). Click a colored paragraph or line to see its counterpart.

One block of code here has a permanent identifier (oscr:b:…), listed with the matches below: citable for good, with a page of its own. Select a match and press Cite to copy it. What a block identifier is.

The 1 match
  1. [1] § MATERIALS AND METHODS › Experimental setup › nnU‐Net for stroke segmentation ↔ data_preprocessing.py, lines 74 to 142 · score 0.53 · gradient descent, mutually, optimizer · block oscr:b:H2RNCFZXVAYYJ-M · Report a mismatch

Paper

Loaded from Europe PMC by your browser; OSCR does not store it: doi.org · Europe PMC

The paper is loaded when this pane is shown.

The authors' code

Python · 233 lines · 6.9 KB · no license · 1 match

  1. """
  2. preprocess_nifti.py
  3. Utilities to:
  4. 1) Upsample a perfusion NIfTI to a desired slice spacing.
  5. 2) Rigidly register another modality to the perfusion image.
  6. 3) Resample the registered image onto the perfusion grid.
  7. 4) Save NIfTI with correct spacing / origin / direction.
  8. Depends on:
  9. - SimpleITK
  10. """
  11. from pathlib import Path
  12. from typing import Union
  13. import SimpleITK as sitk
  14. PathLike = Union[str, Path]
  15. def resample_to_target_slice_spacing(
  16. image: sitk.Image,
  17. target_slice_spacing: float,
  18. slice_axis: int = 2,
  19. interpolator=sitk.sitkLinear,
  20. ) -> sitk.Image:
  21. """
  22. Resample a 3D image to a new slice spacing along one axis.
  23. Parameters
  24. ----------
  25. image : sitk.Image
  26. Input 3D image.
  27. target_slice_spacing : float
  28. Desired spacing (in mm) along the slice axis.
  29. slice_axis : int
  30. Axis index that corresponds to the slice direction (0, 1, or 2).
  31. interpolator : SimpleITK interpolator
  32. E.g., sitk.sitkLinear for intensity images,
  33. sitk.sitkNearestNeighbor for labels.
  34. Returns
  35. -------
  36. sitk.Image
  37. Resampled image with updated slice spacing and correct header
  38. (origin, spacing, direction).
  39. """
  40. if image.GetDimension() != 3:
  41. raise ValueError(f"Expected 3D image, got dimension={image.GetDimension()}")
  42. original_spacing = list(image.GetSpacing())
  43. original_size = list(image.GetSize())
  44. new_spacing = list(original_spacing)
  45. new_spacing[slice_axis] = float(target_slice_spacing)
  46. new_size = []
  47. for i in range(3):
  48. size_i = int(round(original_size[i] * (original_spacing[i] / new_spacing[i])))
  49. new_size.append(max(size_i, 1))
  50. resampler = sitk.ResampleImageFilter()
  51. resampler.SetReferenceImage(image)
  52. resampler.SetSize(new_size)
  53. resampler.SetOutputSpacing(new_spacing)
  54. resampler.SetOutputOrigin(image.GetOrigin())
  55. resampler.SetOutputDirection(image.GetDirection())
  56. resampler.SetInterpolator(interpolator)
  57. return resampler.Execute(image)
  58. def rigid_register_to_fixed(
  59. fixed: sitk.Image,
  60. moving: sitk.Image,
  61. ) -> sitk.Image:
  62. """
  63. Simple rigid (Euler3D) registration of `moving` to `fixed` using
  64. Mattes mutual information and gradient descent, then resample
  65. `moving` onto `fixed` grid.
  66. Parameters
  67. ----------
  68. fixed : sitk.Image
  69. Fixed image (e.g., upsampled perfusion).
  70. moving : sitk.Image
  71. Moving image (other modality).
  72. Returns
  73. -------
  74. sitk.Image
  75. Moving image resampled onto fixed image grid.
  76. Registration is done as in the SimpleITK documentation example:
  77. https://github.com/InsightSoftwareConsortium/SimpleITK-Notebooks/blob/main/Utilities/intro_animation.py
  78. """
  79. # Initialize centered rigid transform
  80. initial_transform = sitk.CenteredTransformInitializer(
  81. fixed,
  82. moving,
  83. sitk.Euler3DTransform(),
  84. sitk.CenteredTransformInitializerFilter.GEOMETRY,
  85. )
  86. reg = sitk.ImageRegistrationMethod()
  87. reg.SetMetricAsMattesMutualInformation(numberOfHistogramBins=50)
  88. reg.SetMetricSamplingStrategy(reg.RANDOM)
  89. reg.SetMetricSamplingPercentage(0.2)
  90. reg.SetInterpolator(sitk.sitkLinear)
  91. # Optimizer: simple gradient descent
  92. reg.SetOptimizerAsGradientDescent(
  93. learningRate=1.0,
  94. numberOfIterations=200,
  95. convergenceMinimumValue=1e-6,
  96. convergenceWindowSize=10,
  97. )
  98. reg.SetOptimizerScalesFromPhysicalShift()
  99. reg.SetShrinkFactorsPerLevel([4, 2, 1])
  100. reg.SetSmoothingSigmasPerLevel([2, 1, 0])
  101. reg.SmoothingSigmasAreSpecifiedInPhysicalUnitsOn()
  102. reg.SetInitialTransform(initial_transform, inPlace=False)
  103. fixed = sitk.Cast(fixed, sitk.sitkFloat32)
  104. moving = sitk.Cast(moving, sitk.sitkFloat32)
  105. final_transform = reg.Execute(fixed, moving)
  106. registered = sitk.Resample(
  107. moving,
  108. fixed,
  109. final_transform,
  110. sitk.sitkLinear,
  111. 0.0,
  112. moving.GetPixelID(),
  113. )
  114. return registered
  115. def save_nifti(image: sitk.Image, path: PathLike) -> None:
  116. """
  117. Save SimpleITK image as NIfTI (.nii or .nii.gz).
  118. Header (spacing, origin, direction) is taken from the image object.
  119. """
  120. path = Path(path)
  121. path.parent.mkdir(parents=True, exist_ok=True)
  122. sitk.WriteImage(image, str(path))
  123. def preprocess_pair(
  124. perfusion_path: PathLike,
  125. modality_path: PathLike,
  126. target_slice_spacing: float,
  127. slice_axis: int,
  128. output_perfusion_path: PathLike,
  129. output_modality_path: PathLike,
  130. ) -> None:
  131. """
  132. 1) Load perfusion image.
  133. 2) Upsample perfusion to desired slice spacing.
  134. 3) Load other modality.
  135. 4) Rigidly register to perfusion.
  136. 5) Resample new modality onto perfusion grid.
  137. 6) Save both new NIfTI files.
  138. Parameters
  139. ----------
  140. perfusion_path : str or Path
  141. Path to perfusion NIfTI.
  142. modality_path : str or Path
  143. Path to other modality NIfTI.
  144. target_slice_spacing : float
  145. Desired slice spacing in mm for perfusion.
  146. slice_axis : int
  147. Axis index corresponding to slice direction (0, 1, or 2).
  148. output_perfusion_path : str or Path
  149. Output path for resampled perfusion NIfTI.
  150. output_modality_path : str or Path
  151. Output path for registered modality NIfTI.
  152. """
  153. perfusion_path = Path(perfusion_path)
  154. modality_path = Path(modality_path)
  155. print(f"[INFO] Reading perfusion from {perfusion_path}")
  156. perfusion_img = sitk.ReadImage(str(perfusion_path))
  157. print(
  158. f"[INFO] Upsampling perfusion to slice spacing {target_slice_spacing} mm "
  159. f"along axis {slice_axis}"
  160. )
  161. perfusion_resampled = resample_to_target_slice_spacing(
  162. perfusion_img,
  163. target_slice_spacing=target_slice_spacing,
  164. slice_axis=slice_axis,
  165. interpolator=sitk.sitkLinear,
  166. )
  167. print(f"[INFO] Reading other modality from {modality_path}")
  168. modality_img = sitk.ReadImage(str(modality_path))
  169. print("[INFO] Rigid registration of other modality to perfusion...")
  170. modality_registered = rigid_register_to_fixed(
  171. fixed=perfusion_resampled,
  172. moving=modality_img,
  173. )
  174. print(f"[INFO] Saving resampled perfusion to {output_perfusion_path}")
  175. save_nifti(perfusion_resampled, output_perfusion_path)
  176. print(f"[INFO] Saving registered other modality to {output_modality_path}")
  177. save_nifti(modality_registered, output_modality_path)
  178. print("[INFO] Done.")
  179. if __name__ == "__main__":
  180. path_to_perfusion_nifti = r"path/to/perfusion/nifti"
  181. path_to_other_modality_nifti = r"path/to/othermodality/nifti"
  182. out_perf = r"path/to/save/resampled/perfusion"
  183. out_other_modality = r"path/to/save/registered/othermodality"
  184. preprocess_pair(
  185. perfusion_path=path_to_perfusion_nifti,
  186. modality_path=path_to_other_modality_nifti,
  187. target_slice_spacing=1,
  188. slice_axis=2,
  189. output_perfusion_path=out_perf,
  190. output_modality_path=out_other_modality,
  191. )

data_preprocessing.py at commit 9ce10f3, no license · at the source

Overview

Authors: Linda Vorberg1,2, Hendrik Ditt2, Andreas Maier1, Savvas Nicolaou3, Nicolas Murray3, Oliver Taubmann2
  1. Pattern Recognition Lab, Friedrich‐Alexander Universität Erlangen‐Nürnberg, Erlangen, Germany
  2. Computed Tomography, Siemens Healthineers AG, Forchheim, Germany
  3. Department of Radiology, Vancouver General Hospital, University of British Columbia, Vancouver, Canada
Journal: Medical physics, volume 53, issue 4, article e70419
Dates: received 4 December 2025; accepted 11 March 2026; published online 3 April 2026; in print April 2026
Type: Research article · Language: English
License: CC BY
Identifiers: DOI 10.1002/mp.70419 · PMID 41933279 · PMCID PMC13049103 · OpenAlex W7149294071
Open access: hybrid, a free copy (OpenAlex)
Status: code verified (how the code is found and verified)
Categories: other (modality), human (organism), stroke (population), methods / tools (subfield)
Methods: Connectivity, Statistics, Machine learning, fMRI & imaging
Keywords: computed tomography, segmentation, stroke
MeSH: Computed Tomography Angiography*, Deep Learning*, Image Processing, Computer-Assisted*, Stroke*, Tomography, X-Ray Computed*, Humans, Time Factors (* major topic)
Topic: Medical Image Segmentation Techniques (Computer Vision and Pattern Recognition, Computer Science), according to OpenAlex
Citations: not cited yet (Europe PMC); 44 references in the paper

Abstract

Background: Stroke imaging typically involves multiple CT image types—non‐contrast CT (NCCT), CT angiography (CTA), and CT perfusion (CTP). CTP and multiphase CTA (mCTA) are more advanced acquisitions with multiple timesteps and provide insights on the hemodynamics within the brain. Deep Learning models can help facilitate the diagnostic workflow by automatically identifying the extent of core and penumbra, which influences subsequent treatment decisions. For the use in clinical practice, generalizability of these models to new clinical sites is crucial.

Purpose: We evaluate and compare the usefulness of NCCT, CTA, mCTA, and CTP images for DL‐based stroke lesion segmentation, with the aim of guiding modality selection in settings with and without access to advanced imaging, and with an additional focus on model transferability between clinical sites and the impact of time point selection from the CTP scan.

Methods: The experiments involve model training with a dataset of 91 stroke patients from one clinical site. NCCT, CTA, mCTA, and CTP are used separately to train nnU‐Net models for segmentation of stroke core and hypoperfused volume using uncertainty‐aware labels. To assess site transferability, a model (pre‐)trained on 166 cases from a second clinical site is employed to perform as‐is inference with data from the first site, then contrast it with a variant of the model fine‐tuned using a subset of the data from the first site. Multiple temporal sampling strategies were investigated for the 4D CTP data, choosing different subsets of the time series as the model input.

Results: For automatic segmentation of stroke core, advanced imaging techniques yield improved accuracy with the modified Dice coefficient increasing from 0.36±0.28 (NCCT) to 0.55±0.27 (CTA), 0.71±0.22 (mCTA), and 0.78±0.09 (CTP) for infarcts of size 10–70 mL. A similar trend is observed for smaller infarcts of 1–10 mL. In terms of generalizability, the additional fine‐tuning stage consistently enhances the segmentation results, regardless of the image type used. To leverage the initially large series of perfusion images, different temporal sampling strategies are applied to predict stroke core. The experiments show no clear trend as the results vary across different timing scenarios and infarct sizes.

Conclusions: The study provides an overview of the quality of automated stroke lesion segmentation with nnU‐Net across all relevant CT acquisition types. Hereby, multitimepoint imaging exhibits significantly improved segmentation performance compared to NCCT and CTA.

Reproduced under the paper's license (CC BY), from the paper cited above.

Repository

Its files are read in the Code ↔ Paper reader above, with 1 match between paragraphs and lines of code.

ac74esiw/stroke_segmentation

License: none: the authors keep all their rights
State: the link answers, verified on 17 November 2026
Evidence: files inventoried
Commit: 9ce10f3f414918c8e5c1f81657179bc927d230ff, 2 December 2025
Languages: Python (1)
Size: 2 files, 1 script
Software Heritage: not archived
Found in: the references
Holds: README
Not found: license file, CITATION.cff, environment file, tests, continuous integration, documentation
Tools: SimpleITK (1 file)
Availability: 2 checks, the latest on 17 November 2026: the link answers
  • 17 November 2026: the link answers
  • 28 September 2026: the link answers
2 files

Tracing map

Proposed by the machine: these links were found in the paper and verified at the source, without human review. The map will receive a Zenodo DOI once one of the paper's authors has validated it with their ORCID.

What the map holds:

  • 1 repository of the authors' code, each at its verified commit, with its license and how the link was found in the paper;
  • 1 script, each with its path and the digest of its content;
  • 1 match between paragraphs of the paper and lines of the code (method lexical-v1);
  • neither the text of the paper nor the code itself.

Its JSON (tracing-map.json) is deposited on Zenodo with its DOI once the map is validated.

Data

No dataset and no data link were found in the paper.

Versions

The history of this record: each version stored by the harvester or made by a correction of its authors or of the maintainers of its code, and what changed in its facts. The texts of the paper (its abstract, its availability statements) are not part of it; versions that changed only those are not listed.

Version 2, 28 September 2026

  • Publisher: n/a → Wiley

Version 1, 28 September 2026: the first record

Recorded: type, language, journal, volume, issue, pages, dates, 6 authors, 3 keywords, 7 MeSH terms, 31 references.

Cite

This paper

Vorberg, L., Ditt, H., Maier, A., Nicolaou, S., Murray, N., & Taubmann, O. (2026). Comparing deep learning stroke segmentation in NCCT, CTA, and CTP: Accuracy, domain transfer, and temporal sampling effect. Medical physics, 53(4), e70419. https://doi.org/10.1002/mp.70419

BibTeX

@article{vorberg2026comparing,
author = {Vorberg, Linda and Ditt, Hendrik and Maier, Andreas and Nicolaou, Savvas and Murray, Nicolas and Taubmann, Oliver},
title = {{Comparing deep learning stroke segmentation in NCCT, CTA, and CTP: Accuracy, domain transfer, and temporal sampling effect}},
journal = {Medical physics},
year = {2026},
month = apr,
volume = {53},
number = {4},
pages = {e70419},
publisher = {Wiley},
issn = {0094-2405},
doi = {10.1002/mp.70419},
url = {https://doi.org/10.1002/mp.70419},
pmid = {41933279},
pmcid = {PMC13049103}
}

RIS

TY - JOUR
AU - Vorberg, Linda
AU - Ditt, Hendrik
AU - Maier, Andreas
AU - Nicolaou, Savvas
AU - Murray, Nicolas
AU - Taubmann, Oliver
TI - Comparing deep learning stroke segmentation in NCCT, CTA, and CTP: Accuracy, domain transfer, and temporal sampling effect
T2 - Medical physics
J2 - Med Phys
PY - 2026
DA - 2026/04/01
VL - 53
IS - 4
SP - e70419
SN - 0094-2405
PB - Wiley
DO - 10.1002/mp.70419
UR - https://doi.org/10.1002/mp.70419
LA - en
ER -

CSL-JSON

{
"id": "10.1002/mp.70419",
"type": "article-journal",
"title": "Comparing deep learning stroke segmentation in NCCT, CTA, and CTP: Accuracy, domain transfer, and temporal sampling effect",
"container-title": "Medical physics",
"author": [
{
"family": "Vorberg",
"given": "Linda"
},
{
"family": "Ditt",
"given": "Hendrik"
},
{
"family": "Maier",
"given": "Andreas"
},
{
"family": "Nicolaou",
"given": "Savvas"
},
{
"family": "Murray",
"given": "Nicolas"
},
{
"family": "Taubmann",
"given": "Oliver"
}
],
"container-title-short": "Med Phys",
"volume": "53",
"issue": "4",
"page": "e70419",
"DOI": "10.1002/mp.70419",
"PMID": "41933279",
"PMCID": "PMC13049103",
"ISSN": "0094-2405",
"publisher": "Wiley",
"URL": "https://doi.org/10.1002/mp.70419",
"language": "en",
"issued": {
"date-parts": [
[
2026,
4,
1
]
]
}
}

The tracing map gets a citation of its own once an author has validated it and it has a DOI.

Similar papers

The papers with a page that share the most with this one: the tools found in their code, their categories, datasets, cited references and authors, the rarest counting most.

[1] doi:10.1038/s41598-023-42961-x [code]
Non-inferiority of deep learning ischemic stroke segmentation on non-contrast CT within 16-hours compared to expert neuroradiologists.
Journal: Scientific reports
In common: SimpleITK, stroke, other, 4 references
[2] doi:10.1161/svin.125.001890 [code]
Estimation of Acute Infarct Core and Hypoperfused Region from Baseline Noncontrast Computed Tomography and Computed Tomography Angiography Scans of Patients with Ischemic Stroke.
Journal: Stroke (Hoboken, N.J.)
In common: stroke, other, 4 references
[3] doi:10.1007/s10278-025-01612-5
Robust Quantification of Affected Brain Volume from Computed Tomography Perfusion: A Hybrid Approach Combining Deep Learning and Singular Value Decomposition.
Journal: Journal of imaging informatics in medicine
In common: stroke, other, 3 references
[4] doi:10.1038/s41598-025-21945-z [code]
A multimodal multitask deep learning model for predicting stroke lesion and functional outcomes using 4D CTP imaging and clinical metadata.
Journal: Scientific reports
In common: stroke, other, 3 references
[5] doi:10.3389/fninf.2023.852105 [code]
Neural network-derived perfusion maps: A model-free approach to computed tomography perfusion in patients with acute ischemic stroke.
Journal: Frontiers in neuroinformatics
In common: stroke, other, 3 references
[6] doi:10.3390/biomedicines12030580 [code]
Segmenting Ischemic Penumbra and Infarct Core Simultaneously on Non-Contrast CT of Patients with Acute Ischemic Stroke Using Novel Convolutional Neural Network.
Journal: Biomedicines
In common: stroke, other, 3 references
[7] doi:10.1007/s13534-025-00462-y [code]
Automatic prediction of stroke treatment outcomes: latest advances and perspectives.
Journal: Biomedical engineering letters
In common: SimpleITK, stroke, 2 references
[8] doi:10.1038/s41467-024-53550-5 [code]
Self-supervised learning for accurately modelling hierarchical evolutionary patterns of cerebrovasculature.
Journal: Nature communications
In common: SimpleITK, stroke, 2 references
[9] doi:10.1038/s41598-022-27350-0 [code]
Automatic segmentation of trabecular and cortical compartments in HR-pQCT images using an embedding-predicting U-Net and morphological post-processing.
Journal: Scientific reports
In common: SimpleITK, methods / tools, 2 references
[10] doi:10.3389/fneur.2024.1330497
Prediction of tissue outcome in acute ischemic stroke based on single-phase CT angiography at admission.
Journal: Frontiers in neurology
In common: stroke, other, 2 references

Contribute

The authors of this paper can claim it, correct its record and validate its tracing map, and the maintainers of its code (its owner, or a public member of its organization) correct what it says of their repository; anyone signed in can ask for its removal. Every request goes to OSCR's own machine, which answers it; your account page follows them.

Sign in with ORCID to claim this paper as one of its authors, correct its record or validate its tracing map: when the paper's metadata lists your ORCID iD, you are recognized at once. Maintainers of its code: sign in with GitHub, then claim the repository on your account page.

Add the badge to the code's README

OSCR: the badge of this paper

If you are an author or a maintainer of this paper's code, you can add this badge. It says what OSCR knows of the paper (its code, its validated tracing map) and links the code to this page. Paste one of these snippets under the README's title. Keep the two marks around it, so that the badge can be replaced in place and is never added twice. OSCR changes nothing in your repository.

Markdown
<!-- oscr-badge:start -->
[![OSCR](https://openscicode.org/badge/doi/10.1002/mp.70419.svg)](https://openscicode.org/badge/doi/10.1002/mp.70419)
<!-- oscr-badge:end -->
reStructuredText
.. oscr-badge:start

.. image:: https://openscicode.org/badge/doi/10.1002/mp.70419.svg
   :target: https://openscicode.org/badge/doi/10.1002/mp.70419
   :alt: OSCR

.. oscr-badge:end
HTML
<!-- oscr-badge:start -->
<a href="https://openscicode.org/badge/doi/10.1002/mp.70419"><img src="https://openscicode.org/badge/doi/10.1002/mp.70419.svg" alt="OSCR"></a>
<!-- oscr-badge:end -->

On GitHub, open the README, choose Edit (the pencil), paste the snippet under the title, then "Commit changes".

If you choose to, you can have the badge kept up to date for you, with oscr badge --write from the command line or with the GitHub Action in your repository's workflows. Every other form and option (a card, AsciiDoc, LaTeX, shields.io) is on the badge page.

Request its removal

To ask OSCR to remove this record, the copies of its authors' scripts or its tracing map, use the removal request page: signed in, you say who you are, what to remove and why, then review and confirm the request. Published rules decide every request (how).

Discussion, reproductions, activity

Discussion: code errors and mismatches between the code and the paper about this paper and its code, from readers and its authors, beside the paper and its tracing map.

Report a mismatch between the code and the paper · Report a code error (signed in)

Reproductions: reports from readers who ran the authors' code and did not get the paper's result, what they ran, with which environment, commit and data.

Report a reproduction failure (signed in)

Versions of its code: the releases of its code tied to a version of this paper (the preprint, the accepted manuscript, the version of record…), each with the tracing map versioned with it.

Activity: what happens around this paper: new versions of its record, its map's validation, discussions and reproductions. It opens with sign-in.