SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2404.09556 · 2024

nnU-Net Revisited: A Call for Rigorous Validation in 3D Medical Image Segmentation

arXiv · PDF · Open in the Atlas

Code that ran

7 of 7 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 1 honoured the contract we drafted, 1 violated it and 3 have no contract verdict; 2 failures of our instrument; 0 no recorded run), measured 2026-11-22; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2404.09556.json · badge: /api/ran/2404.09556.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
MIC-DKFZ/nnunet canonical (classifier label)
classifier basis: census
3 ran · 0 no recorded run
DeepMicroscopy/nnUNet community (classifier label)
classifier basis not recorded on the link
4 ran · 0 no recorded run
FunctionStatusWhere it lives
calculate_confusion_matrix Ran
ran on a synthesized input
DeepMicroscopy/nnUNet/nnunetv2/evaluation.py
code served (permissive licence) · get_code("58d38fedb5114f60")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned ndarray, ndim 2, dtype family int, shape (3, 3) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np
import torch

torch.manual_seed(0)

# Create small test arrays for confusion matrix calculation
# pred_mask: predicted class labels (values 0 to num_classes-1)
# true_mask: ground truth class labels (values 0 to num_classes-1)
# num_classes: number of classes

num_classes = 3

# Create pred_mask: predicted labels for 10 pixels
pred_mask = np.array([0, 1, 2, 0, 1, 2, 0, 1, 2, 0], dtype=np.int32)

# Create true_mask: ground truth labels for 10 pixels
# Include some invalid values (< 0 or >= num_classes) to test masking
true_mask = np.array([0, 1, 1, 0, 2, 2, 1, 1, 0, 2], dtype=np.int32)

ARGS = {
    "pred_mask": pred_mask,
    "true_mask": true_mask,
    "num_classes": num_classes,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 2, dtype family int, shape (3, 3) — shape (3, 3) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
comp_blosc2_params Ran
ran; the contract check could not run (RAISES, DEP_MISSING or TIMEOUT)
MIC-DKFZ/nnunet/nnunetv2/training/dataloading/nnunet_dataset.py
code served (permissive licence) · get_code("f8636c471203bf8b")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned tuple, ndim 2, dtype family int; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import math
from typing import Optional, Sequence, Tuple

torch_imported = False
try:
    import torch
    torch_imported = True
except ImportError:
    pass

# Construct valid arguments for comp_blosc2_params
image_size = (3, 128, 256, 512)  # (c, x, y, z) - 4D spatial image
patch_size = (32, 64, 128)  # (x, y, z) - 3D spatial patch
bytes_per_pixel = 4
max_block_nbytes = 128 * 1024
max_chunk_nbytes = 6 * 1024 ** 2
max_chunk_to_patch_ratio_per_axis = 1.5
grow_singleton_patch_axes = False

ARGS = {
    'image_size': image_size,
    'patch_size': patch_size,
    'bytes_per_pixel': bytes_per_pixel,
    'max_block_nbytes': max_block_nbytes,
    'max_chunk_nbytes': max_chunk_nbytes,
    'max_chunk_to_patch_ratio_per_axis': max_chunk_to_patch_ratio_per_axis,
    'grow_singleton_patch_axes': grow_singleton_patch_axes,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 2, dtype family int — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
convert_labels_back_to_BraTS Ran
ran, violated the contract we drafted
DeepMicroscopy/nnUNet/nnunetv2/dataset_conversion/Dataset042_BraTS18.py
code served (permissive licence) · get_code("a2c8b38ba9393780")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned ndarray, ndim 3, dtype family int, shape (2, 3, 4) as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np

# Create a small segmentation array for testing
# The array has values 0, 1, 2, 3 which will be converted
seg = np.array([
    [[0, 1, 2, 3],
     [1, 0, 3, 2],
     [2, 3, 0, 1]],
    [[3, 2, 1, 0],
     [0, 1, 2, 3],
     [1, 2, 3, 0]]
], dtype=np.uint8)

ARGS = {
    "seg": seg
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type ndarray, ndim 3, dtype family int, shape (2, 3, 4) — shape (2, 3, 4) as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
copy_files Ran
ran, honoured the contract we drafted
MIC-DKFZ/nnunet/nnunetv2/dataset_conversion/Dataset027_ACDC.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from luumsk/SmallLesionMRI, is pointer only (licence: NONE) · get_code("517ad51ee69e8a2d")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (Apache-2.0), but get_code serves the stored copy, first harvested from luumsk/SmallLesionMRI, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

mean_iou Ran
ran on a synthesized input
DeepMicroscopy/nnUNet/nnunetv2/evaluation.py
code served (permissive licence) · get_code("9235f33692fd804d")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned float64, ndim 0, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import os
import numpy as np
import cv2
import tempfile
import shutil

# Create temporary directories with test mask files
temp_dir = tempfile.mkdtemp()
true_masks_dir = os.path.join(temp_dir, 'true_masks')
pred_masks_dir = os.path.join(temp_dir, 'pred_masks')
os.makedirs(true_masks_dir)
os.makedirs(pred_masks_dir)

# Create sample grayscale mask images for testing
scanner_name = 'scanner_A'
num_test_files = 2
mask_height, mask_width = 64, 64

for i in range(num_test_files):
    # Create true masks
    true_mask = np.random.randint(0, 4, (mask_height, mask_width), dtype=np.uint8)
    true_mask_path = os.path.join(true_masks_dir, f'mask_{scanner_name}_{i}.png')
    cv2.imwrite(true_mask_path, true_mask)
    
    # Create predicted masks
    pred_mask = np.random.randint(0, 4, (mask_height, mask_width), dtype=np.uint8)
    pred_mask_path = os.path.join(pred_masks_dir, f'mask_{scanner_name}_{i}.png')
    cv2.imwrite(pred_mask_path, pred_mask)

ARGS = {
    'true_masks_dir': true_masks_dir,
    'pred_masks_dir': pred_masks_dir,
    'scanner': scanner_name,
    'num_classes': 4
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
cv2, numpy, tqdm — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type float64, ndim 0, dtype family float — no output shape is stated: observe_signature.py recorded float ndim 0, which disagrees with the fixture run
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
mean_iou_from_confusion_matrix Ran
ran on a synthesized input
DeepMicroscopy/nnUNet/nnunetv2/evaluation.py
code served (permissive licence) · get_code("1ce6a0bc9d7ba540")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API) and returned float32, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import numpy as np

# Create a small confusion matrix
# Shape: (num_classes, num_classes)
# num_classes = 5, so we skip class 3 in the loop
confusion_matrix = np.array([
    [10, 2, 1, 0, 0],    # class 0
    [1, 8, 2, 0, 1],     # class 1
    [0, 1, 12, 0, 2],    # class 2
    [0, 0, 0, 0, 0],     # class 3 (skipped in loop)
    [1, 0, 2, 0, 9],     # class 4
], dtype=np.float32)

num_classes = 5

ARGS = {
    "confusion_matrix": confusion_matrix,
    "num_classes": num_classes,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1, through the batch API
Imports
numpy — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type float32, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
merge Ran
ran; our contract draft was wrong, not the code
MIC-DKFZ/nnunet/nnunetv2/batch_running/generate_lsf_runs_customDecathlon.py
pointer only (licence: Apache-2.0); the stored copy get_code serves, from luumsk/SmallLesionMRI, is pointer only (licence: NONE) · get_code("86ec2ccc2984b8bf")
How it ran

The body of this sample is withheld: this paper's link allows the body inline (Apache-2.0), but get_code serves the stored copy, first harvested from luumsk/SmallLesionMRI, and GitHub detected no licence in that repository when it was checked. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

Also present in other papers' code

Of 7 samples lifted from this paper's linked repositories, 7 carry a function identity and 0 do not. Of the 7 distinct functions with an identity, 3 are also present in other papers whose code we hold (3 with at least one paper dated earlier, 0 the same month, 3 later) and 4 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

FunctionAlso present inEarliest-datedOthers named
merge 11 other papers
5 dated earlier, 6 later
2303.14444 (2023-03)
MultiTalent: A Multi-Dataset Approach to Medical Image Segmentation
2309.03906 (2023-09)
A-Eval: A Benchmark for Cross-Dataset Evaluation of Abdominal Multi-Organ Segmentation
2402.03302 (2024-02)
Swin-UMamba: Mamba-based UNet with ImageNet-based pretraining
and 8 more not named here
copy_files 10 other papers
4 dated earlier, 6 later
2309.03906 (2023-09)
A-Eval: A Benchmark for Cross-Dataset Evaluation of Abdominal Multi-Organ Segmentation
2402.03302 (2024-02)
Swin-UMamba: Mamba-based UNet with ImageNet-based pretraining
2403.05246 (2024-03)
LightM-UNet: Mamba Assists in Lightweight UNet for Medical Image Segmentation
and 7 more not named here
convert_labels_back_to_BraTS 9 other papers
6 dated earlier, 3 later
2106.01226 (2021-06)
Semi-Supervised Semantic Segmentation with Cross Pseudo Supervision
2205.04846 (2022-05)
MNet: Rethinking 2D/3D Networks for Anisotropic Medical Image Segmentation
2303.09975 (2023-03)
MedNeXt: Transformer-driven Scaling of ConvNets for Medical Image Segmentation
and 6 more not named here

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-22.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

The release of nnU-Net marked a paradigm shift in 3D medical image segmentation, demonstrating that a properly configured U-Net architecture could still achieve state-of-the-art results. Despite this, the pursuit of novel architectures, and the respective claims of superior performance over the U-Net baseline, continued. In this study, we demonstrate that many of these recent claims fail to hold up when scrutinized for common validation shortcomings, such as the use of inadequate baselines, insufficient datasets, and neglected computational resources. By meticulously avoiding these pitfalls, we conduct a thorough and comprehensive benchmarking of current segmentation methods including CNN-based, Transformer-based, and Mamba-based approaches. In contrast to current beliefs, we find that the recipe for state-of-the-art performance is 1) employing CNN-based U-Net models, including ResNet and ConvNeXt variants, 2) using the nnU-Net framework, and 3) scaling models to modern hardware resources. These results indicate an ongoing innovation bias towards novel architectures in the field and underscore the need for more stringent validation standards in the quest for scientific progress.

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2404.09556")
get_code_for_paper("2404.09556")
have("2404.09556")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2404.09556.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2404.09556.svg)](https://syntology.ai/paper/2404.09556)

Connect an agent — have() is free.