NeXtSwin-X: dual-branch cross-attention fusion of ConvNeXt and swin transformer for accurate brain tumor classification from MRI and CT.
The 8 matches
- [1] § Datasets and methodology › Training and evaluation protocol ↔ Brain_Tumor_Classification_Nickparvar.ipynb, lines 319–440 · score 0.70 · AdamW, weight decay, head learning rates, Nickparvar, cross attention, ConvNeXt
- [2] § Datasets and methodology › Training and evaluation protocol ↔ Brain_Tumor_Classification_Ahmed.ipynb, lines 323–444 · score 0.68 · Cross Entropy Loss, Cosine Annealing, smoothing, scheduler, optimization, epochs
- [3] § Datasets and methodology › Training and evaluation protocol ↔ Brain_Tumor_Classification_BRISC.ipynb, lines 316–452 · score 0.68 · Cross Entropy Loss, Cosine Annealing, smoothing, scheduler, optimization, epochs
- [4] § Datasets and methodology › Training and evaluation protocol ↔ Brain_Tumor_Classification_Ahmed.ipynb, lines 323–444 · score 0.67 · AdamW, weight decay, head learning rates, cross attention, ConvNeXt, optimized
- [5] § Datasets and methodology › Data preprocessing and augmentation ↔ Brain_Tumor_Classification_Navoneel.ipynb, lines 25–88 · score 0.61 · random horizontal flips, random rotations, brightness, translations, MRI, transformations
- [6] § Datasets and methodology › Data preprocessing and augmentation ↔ Brain_Tumor_Classification_Nickparvar.ipynb, lines 24–89 · score 0.61 · random horizontal flips, random rotations, brightness, translations, MRI, transformations
- [7] § Datasets and methodology › The proposed dual-branch fusion architecture ↔ Brain_Tumor_Classification_BRISC.ipynb, lines 165–294 · score 0.55 · Layer Normalization, CNN features, linear, module, query, head
- [8] § Datasets and methodology › The proposed dual-branch fusion architecture ↔ Brain_Tumor_Classification_Navoneel.ipynb, lines 169–287 · score 0.55 · Layer Normalization, CNN features, linear, module, query, head
Paper
Loaded from Europe PMC by your browser, not stored by OSCR: doi.org · Europe PMC
The paper is loaded when this pane is shown.
The authors' code
Jupyter notebook · 561 lines · 18 KB · MIT · 2 matches
- # %% [markdown]
- # ## Environment Setup
- # %%
- ! pip install kagglehub
- # %%
- import kagglehub
- path = kagglehub.dataset_download("masoudnickparvar/brain-tumor-mri-dataset")
- print("Path to dataset files:", path)
- # %%
- from google.colab import drive
- import os
- drive.mount('/content/drive')
- model_save_dir = '/content/drive/My Drive/Brain_Tumor_Nickparvar_Models'
- os.makedirs(model_save_dir, exist_ok=True)
- print(f"Model weights will be saved in: {model_save_dir}")
- # %% [markdown]
- # ## Data Loaders Setup
- # %%
- ! pip install timm ttach -q
- # %%
- import os
- import torch
- from torch.utils.data import DataLoader, WeightedRandomSampler, random_split
- from torchvision import transforms
- from torchvision.datasets import ImageFolder
- from torch.utils.data import Subset
- train_transform = transforms.Compose([
- transforms.Resize((224, 224)),
- transforms.RandomHorizontalFlip(p=0.5),
- transforms.RandomRotation(15),
- transforms.RandomAffine(0, translate=(0.1, 0.1)),
- transforms.ColorJitter(brightness=0.2, contrast=0.2),
- transforms.ToTensor(),
- transforms.Normalize([0.485, 0.456, 0.406], [0.229, 0.224, 0.225]),
- ])
- val_test_transform = transforms.Compose([
- transforms.Resize((224, 224)),
- transforms.ToTensor(),
- transforms.Normalize([0.485, 0.456, 0.406], [0.229, 0.224, 0.225]),
- ])
- base_dir = "/kaggle/input/brain-tumor-mri-dataset"
- train_dir = os.path.join(base_dir, "Training")
- test_dir = os.path.join(base_dir, "Testing")
- full_train_dataset = ImageFolder(train_dir, transform=train_transform)
- train_size = int(0.7 * len(full_train_dataset))
- val_size = int(0.2 * len(full_train_dataset))
- test_size = len(full_train_dataset) - train_size - val_size
- train_ds, val_ds, test_ds = random_split(
- full_train_dataset,
- [train_size, val_size, test_size],
- generator=torch.Generator().manual_seed(42)
- )
- val_ds = Subset(full_train_dataset, val_ds.indices)
- val_ds.dataset.transform = val_test_transform
- test_ds = Subset(full_train_dataset, test_ds.indices)
- test_ds.dataset.transform = val_test_transform
- train_targets = [full_train_dataset.targets[i] for i in train_ds.indices]
- class_counts = torch.bincount(torch.tensor(train_targets))
- class_weights = 1.0 / class_counts.float()
- sample_weights = [class_weights[label] for label in train_targets]
- sampler = WeightedRandomSampler(sample_weights, num_samples=len(sample_weights), replacement=True)
- train_loader = DataLoader(train_ds, batch_size=32, sampler=sampler, num_workers=2, pin_memory=True)
- val_loader = DataLoader(val_ds, batch_size=32, shuffle=False, num_workers=2, pin_memory=True)
- test_loader = DataLoader(test_ds, batch_size=32, shuffle=False, num_workers=2, pin_memory=True)
- print("Done setting up data loaders.")
- print(f"Total training images: {len(train_ds)}")
- print(f"Total validation images: {len(val_ds)}")
- print(f"Total test images: {len(test_ds)}")
- print(f"Classes: {full_train_dataset.classes}")
- # %% [markdown]
- # ## Exploratory Data Analysis (EDA)
- # %%
- import matplotlib.pyplot as plt
- import seaborn as sns
- import numpy as np
- plt.style.use('seaborn-v0_8-whitegrid')
- sns.set_context("talk")
- class_names = full_train_dataset.classes
- class_counts = np.bincount(full_train_dataset.targets)
- formatted_class_names = []
- for name in class_names:
- if name == 'notumor':
- formatted_class_names.append('No Tumor')
- else:
- formatted_class_names.append(name.capitalize())
- pie_colors = sns.color_palette("Set2", len(class_names))
- plt.figure(figsize=(12, 10))
- wedges, texts, autotexts = plt.pie(
- class_counts,
- labels=formatted_class_names,
- autopct='%1.1f%%',
- startangle=140,
- colors=pie_colors,
- textprops={'fontsize': 14},
- wedgeprops={'edgecolor': 'black', 'linewidth': 0.75}
- )
- plt.setp(autotexts, size=12, weight="bold", color="white")
- plt.title(
- 'Class Distribution in the Full Training Dataset',
- fontweight='bold',
- fontsize=20,
- pad=20
- )
- plt.axis('equal')
- plt.show()
- split_sizes = {
- 'Training': len(train_ds),
- 'Validation': len(val_ds),
- 'Test': len(test_ds)
- }
- bar_colors = sns.color_palette("Paired", len(split_sizes))
- plt.figure(figsize=(10, 7))
- ax = sns.barplot(
- x=list(split_sizes.keys()),
- y=list(split_sizes.values()),
- palette=bar_colors,
- edgecolor='black',
- linewidth=1.5
- )
- ax.set_title('Dataset Image Distribution Across Splits', fontsize=20, fontweight='bold', pad=20)
- ax.set_xlabel('Dataset Split', fontsize=16, fontweight='bold')
- ax.set_ylabel('Number of Images', fontsize=16, fontweight='bold')
- ax.tick_params(axis='x', labelsize=14)
- ax.tick_params(axis='y', labelsize=12)
- for i, (split, size) in enumerate(split_sizes.items()):
- ax.text(i, size + 50, f'{size:,}', ha='center', va='bottom', fontsize=14, fontweight='bold')
- plt.ylim(0, max(split_sizes.values()) * 1.15)
- sns.despine(top=True, right=True)
- plt.tight_layout()
- plt.show()
- # %% [markdown]
- # ## Model Architecture
- # %%
- import timm
- import torch
- import torch.nn as nn
- import torch.nn.functional as F
- # CNN-only
- class CNN_Only_Model(nn.Module):
- def __init__(self, num_classes=4, pretrained=True):
- super().__init__()
- self.backbone = timm.create_model(
- "convnext_base",
- pretrained=pretrained,
- num_classes=0
- )
- in_features = self.backbone.head.in_features
- self.classifier = nn.Linear(in_features, num_classes)
- def forward(self, x):
- feats = self.backbone(x)
- return self.classifier(feats)
- # Transformer-only
- class Transformer_Only_Model(nn.Module):
- def __init__(self, num_classes=4, pretrained=True):
- super().__init__()
- self.vit = timm.create_model(
- "swin_base_patch4_window7_224",
- pretrained=pretrained,
- num_classes=num_classes
- )
- def forward(self, x):
- return self.vit(x)
- # Dual-Branch
- class DualBranch_Model(nn.Module):
- def __init__(
- self,
- num_classes=4,
- fusion_dim=512,
- num_heads=8,
- dropout=0.1,
- pretrained=True,
- ):
- super().__init__()
- # CNN branch: ConvNeXt
- self.cnn_branch = timm.create_model(
- "convnext_base", pretrained=pretrained, num_classes=0
- )
- cnn_out = self.cnn_branch.head.in_features
- self.cnn_proj = nn.Linear(cnn_out, fusion_dim)
- # Transformer branch: Swin Transformer
- self.transformer_branch = timm.create_model(
- "swin_base_patch4_window7_224", pretrained=pretrained, num_classes=0
- )
- trans_out = self.transformer_branch.head.in_features
- self.trans_proj = nn.Linear(trans_out, fusion_dim)
- # Cross-Attention
- self.cross_attention = nn.MultiheadAttention(
- embed_dim=fusion_dim,
- num_heads=num_heads,
- dropout=dropout,
- batch_first=False
- )
- self.fusion_norm = nn.LayerNorm(fusion_dim)
- self.classifier = nn.Sequential(
- nn.Linear(fusion_dim, fusion_dim // 2),
- nn.ReLU(),
- nn.Dropout(0.5),
- nn.Linear(fusion_dim // 2, num_classes)
- )
- def forward(self, x):
- cnn_feats = self.cnn_branch(x)
- cnn_proj = self.cnn_proj(cnn_feats)
- trans_feats = self.transformer_branch(x)
- trans_proj = self.trans_proj(trans_feats)
- cnn_query = cnn_proj.unsqueeze(0)
- trans_kv = trans_proj.unsqueeze(0)
- attn_output, _ = self.cross_attention(
- query=cnn_query,
- key=trans_kv,
- value=trans_kv
- )
- attn_output = attn_output.squeeze(0)
- fused_features = self.fusion_norm(cnn_proj + attn_output)
- out_main = self.classifier(fused_features)
- return out_main
- # ResNet Model
- class ResNet_Model(nn.Module):
- def __init__(self, num_classes=4, pretrained=True):
- super().__init__()
- self.backbone = timm.create_model(
- "resnet50",
- pretrained=pretrained,
- num_classes=num_classes
- )
- def forward(self, x):
- return self.backbone(x)
- # EfficientNetV2 Model
- class EfficientNetV2_Model(nn.Module):
- def __init__(self, num_classes=4, pretrained=True):
- super().__init__()
- self.backbone = timm.create_model(
- "tf_efficientnetv2_b3",
- pretrained=pretrained,
- num_classes=num_classes
- )
- def forward(self, x):
- return self.backbone(x)
- # %%
- from sklearn.metrics import confusion_matrix
- import seaborn as sns
- import matplotlib.pyplot as plt
- def plot_confusion_matrix(labels, preds, class_names, model_name):
- formatted_class_names = []
- for name in class_names:
- if name == 'notumor':
- formatted_class_names.append('No Tumor')
- else:
- formatted_class_names.append(name.capitalize())
- cm = confusion_matrix(labels, preds)
- plt.figure(figsize=(9, 7))
- heatmap = sns.heatmap(cm, annot=True, fmt='d', cmap='Blues',
- xticklabels=formatted_class_names, yticklabels=formatted_class_names)
- plt.title(f'Confusion Matrix - {model_name} (Test Set)', fontsize=16)
- plt.xlabel('Predicted Label', fontsize=12)
- plt.ylabel('True Label', fontsize=12)
- plt.xticks(rotation=45, ha="right")
- plt.yticks(rotation=0)
- plt.tight_layout()
- plt.show()
- # %% [markdown]
- # ## Training and Evaluation Loop
- # %%
- import time
- import torch
- import torch.nn as nn
- import torch.optim as optim
- from torch.optim.lr_scheduler import CosineAnnealingLR
- from torch.cuda.amp import GradScaler, autocast
- from torch.utils.data import DataLoader
- from tqdm import tqdm
- import ttach as tta
- from sklearn.metrics import classification_report
- import pandas as pd
- from sklearn.exceptions import UndefinedMetricWarning
- import warnings
- warnings.filterwarnings("ignore", category=UndefinedMetricWarning)
- def evaluate_model(model, dataloader, device, class_names):
- model.eval()
- all_labels, all_preds = [], []
- with torch.no_grad():
- for images, labels in dataloader:
- images, labels = images.to(device, non_blocking=True), labels.to(device, non_blocking=True)
- with torch.cuda.amp.autocast():
- outputs = model(images)
- _, predicted = torch.max(outputs, 1)
- all_labels.extend(labels.cpu().numpy())
- all_preds.extend(predicted.cpu().numpy())
- report = classification_report(all_labels, all_preds, target_names=class_names, output_dict=True, zero_division=0)
- return report, all_labels, all_preds
- def train_and_evaluate(
- model, model_name, train_loader, val_loader, test_loader,
- device, class_names, num_epochs=12, transformer_lr=1e-5,
- cnn_lr=3e-5, head_lr=1e-4, weight_decay=1e-4,
- ):
- print(f"\n{'='*35}\n Starting Training for: {model_name}\n{'='*35}")
- model.to(device)
- criterion = nn.CrossEntropyLoss(label_smoothing=0.1)
- if 'Dual_Branch' in model_name:
- param_groups = [
- {'params': model.transformer_branch.parameters(), 'lr': transformer_lr},
- {'params': model.cnn_branch.parameters(), 'lr': cnn_lr},
- {'params': model.cnn_proj.parameters(), 'lr': head_lr},
- {'params': model.trans_proj.parameters(), 'lr': head_lr},
- {'params': model.cross_attention.parameters(), 'lr': head_lr},
- {'params': model.fusion_norm.parameters(), 'lr': head_lr},
- {'params': model.classifier.parameters(), 'lr': head_lr},
- ]
- optimizer = optim.AdamW(param_groups, weight_decay=weight_decay)
- print(f"Using differential LRs: Transformer={transformer_lr}, CNN={cnn_lr}, Head={head_lr}")
- else:
- single_lr = cnn_lr if ('ConvNeXt' in model_name or 'ResNet' in model_name or 'EfficientNet' in model_name) else transformer_lr
- optimizer = optim.AdamW(model.parameters(), lr=single_lr, weight_decay=weight_decay)
- print(f"Using single LR: {single_lr}")
- scheduler = CosineAnnealingLR(optimizer, T_max=num_epochs, eta_min=1e-6)
- scaler = GradScaler()
- best_val_acc = 0.0
- base_save_path = "/content/drive/My Drive/Brain_Tumor_Nickparvar_Models"
- best_model_save_path = f"{base_save_path}/best_{model_name}.pth"
- last_model_save_path = f"{base_save_path}/last_{model_name}.pth"
- start_time = time.time()
- for epoch in range(num_epochs):
- model.train()
- running_loss = 0.0
- train_bar = tqdm(train_loader, desc=f"Epoch {epoch+1}/{num_epochs} [Train]", leave=False)
- for images, labels in train_bar:
- images, labels = images.to(device, non_blocking=True), labels.to(device, non_blocking=True)
- optimizer.zero_grad(set_to_none=True)
- with autocast():
- outputs = model(images)
- loss = criterion(outputs, labels)
- scaler.scale(loss).backward()
- scaler.step(optimizer)
- scaler.update()
- running_loss += loss.item()
- val_report, _, _ = evaluate_model(model, val_loader, device, class_names)
- val_acc = val_report['accuracy'] * 100
- scheduler.step()
- print(f"Epoch {epoch+1:02d} | Train Loss: {running_loss/len(train_loader):.4f} | "
- f"Val Acc: {val_acc:.2f}% | Val F1: {val_report['weighted avg']['f1-score']:.4f} | "
- f"LR: {scheduler.get_last_lr()[0]:.2e}")
- if val_acc > best_val_acc:
- best_val_acc = val_acc
- torch.save(model.state_dict(), best_model_save_path)
- print(f" -> New best model saved to Drive with Val Acc: {best_val_acc:.2f}%")
- training_time = time.time() - start_time
- print(f"\nTraining for {model_name} finished in {training_time/60:.2f} minutes.")
- torch.save(model.state_dict(), last_model_save_path)
- print(f"Saved final model state to '{last_model_save_path}'")
- print(f"Loading best model from '{best_model_save_path}' for final evaluation...")
- model.load_state_dict(torch.load(best_model_save_path, map_location=device))
- print("\nCalculating metrics for the BEST model on all data splits...")
- val_metrics, _, _ = evaluate_model(model, val_loader, device, class_names)
- test_normal_metrics, test_labels, test_preds = evaluate_model(model, test_loader, device, class_names)
- tta_model = tta.ClassificationTTAWrapper(model, tta.aliases.hflip_transform())
- test_tta_metrics, _, _ = evaluate_model(tta_model, test_loader, device, class_names)
- final_results = {
- 'Validation': val_metrics,
- 'Test (Normal)': test_normal_metrics,
- 'Test (TTA)': test_tta_metrics,
- 'Test_Labels_Preds': (test_labels, test_preds)
- }
- return final_results
- # %% [markdown]
- # ## Model Training
- # %%
- import warnings
- warnings.filterwarnings("ignore", category=FutureWarning)
- warnings.filterwarnings("ignore", category=UserWarning)
- device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
- num_classes = len(full_train_dataset.classes)
- class_names = full_train_dataset.classes
- epochs = 10
- weight_decay = 1e-2
- convnext_lr = 1e-5
- swin_lr = 3e-5
- resnet_lr = 3e-5
- efficientnet_lr = 3e-5
- dual_transformer_lr = 6e-5
- dual_cnn_lr = 1e-5
- dual_head_lr = 1e-4
- all_model_results = {}
- model_builders = {
- "Dual_Branch_Swin_ConvNeXt": lambda: DualBranch_Model(num_classes=num_classes),
- "Swin_Transformer_Only": lambda: Transformer_Only_Model(num_classes=num_classes),
- "ConvNeXt_Only": lambda: CNN_Only_Model(num_classes=num_classes),
- "ResNet50": lambda: ResNet_Model(num_classes=num_classes),
- "EfficientNetV2_B3": lambda: EfficientNetV2_Model(num_classes=num_classes),
- }
- for name, builder in model_builders.items():
- try:
- model_instance = torch.compile(builder())
- print(f"\n=== Running experiment: {name} (Compiled) ===")
- except Exception:
- print(f"\n=== Running experiment: {name} (Not Compiled) ===")
- model_instance = builder()
- if 'Dual_Branch' in name:
- lr_params = {'transformer_lr': dual_transformer_lr, 'cnn_lr': dual_cnn_lr, 'head_lr': dual_head_lr}
- elif 'Swin' in name:
- lr_params = {'cnn_lr': swin_lr, 'transformer_lr': swin_lr, 'head_lr': swin_lr}
- elif 'ConvNeXt' in name:
- lr_params = {'cnn_lr': convnext_lr, 'transformer_lr': convnext_lr, 'head_lr': convnext_lr}
- elif 'ResNet' in name:
- lr_params = {'cnn_lr': resnet_lr, 'transformer_lr': resnet_lr, 'head_lr': resnet_lr}
- else:
- lr_params = {'cnn_lr': efficientnet_lr, 'transformer_lr': efficientnet_lr, 'head_lr': efficientnet_lr}
- detailed_results = train_and_evaluate(
- model=model_instance,
- model_name=name,
- train_loader=train_loader,
- val_loader=val_loader,
- test_loader=test_loader,
- device=device,
- class_names=class_names,
- num_epochs=epochs,
- weight_decay=weight_decay,
- **lr_params
- )
- all_model_results[name] = detailed_results
- del model_instance
- torch.cuda.empty_cache()
- # %% [markdown]
- # ## Confusion Matrix Visualization
- # %%
- print("\n\n" + "="*60)
- print(" MODEL CONFUSION MATRICES")
- print("="*60)
- for model_name, results in all_model_results.items():
- if 'Test_Labels_Preds' in results:
- labels, preds = results['Test_Labels_Preds']
- plot_confusion_matrix(labels, preds, class_names, model_name)
- # %% [markdown]
- # ## Results Summary
- # %%
- import pandas as pd
- print("\n\n" + "="*60)
- print(" COMPREHENSIVE MODEL PERFORMANCE REPORT")
- print("="*60)
- report_data = []
- for model_name, results in all_model_results.items():
- for split_name, metrics in results.items():
- if split_name == 'Test_Labels_Preds':
- continue
- weighted_avg = metrics['weighted avg']
- report_data.append({
- 'Model': model_name,
- 'Split': split_name,
- 'Accuracy': metrics['accuracy'] * 100,
- 'F1-Score': weighted_avg['f1-score'],
- 'Precision': weighted_avg['precision'],
- 'Recall': weighted_avg['recall']
- })
- df_report = pd.DataFrame(report_data)
- df_report = df_report.set_index(['Model', 'Split'])
- pd.options.display.float_format = '{:,.4f}'.format
- df_report['Accuracy'] = df_report['Accuracy'].map('{:.2f}%'.format)
- print(df_report.to_string())
- print("\n" + "="*60)
- print("Analysis Complete.")
Brain_Tumor_Classification_Nickparvar.ipynb at commit d76ba08, under MIT · at the source
Overview
Abstract
The abstract is not reproduced here: the paper's license (CC BY-NC-ND) does not allow it. Read it in the paper, at the publisher or on Europe PMC.
Repository
Its files are read in the Code ↔ Paper reader above, with 8 matches between paragraphs and lines of code.
ArashNasrEsfahani/NeXtSwin-X
d76ba083a8a9d1b93a8cefecd412c3549dce33ea, 3 October 2025Availability: 1 check, the latest on 30 September 2026: the link answers
- 30 September 2026: the link answers
8 files
- Brain_Tumor_Classificati
on_Ahmed.ipynb , Jupyter, 566 lines, 2 matches - Brain_Tumor_Classificati
on_BRISC.ipynb , Jupyter, 573 lines, 2 matches - Brain_Tumor_Classificati
on_Navoneel.ipynb , Jupyter, 555 lines, 2 matches - Brain_Tumor_Classificati
on_Nickparvar.ipynb , Jupyter, 561 lines, 2 matches - Brain_Tumor_Classificati
on_Orvile.ipynb , Jupyter, 549 lines - Brain_Tumor_Classificati
on_Sartaj.ipynb , Jupyter, 558 lines - LICENSE, License, 21 lines
- README.md, Text, 99 lines
Code availability statement
The paper has a code availability statement. Its license (CC BY-NC-ND) does not allow reproducing it here; in short, from what the harvester recognized in it:
- it points to the authors' code: ArashNasrEsfahani/
NeXtSwin-X
Read it in the paper: doi.org/10.1038/s41598-026-50158-1.
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;
- 6 scripts, each with its path and the digest of its content;
- 8 matches 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
Datasets cited
- doi:10.17632/
mk56jw9rns.1 , at the source; found in the references - kaggle.com/
datasets/ , at Kaggle; found in the referencesahmedhamada0 - kaggle.com/
datasets/ , at Kaggle; found in the referencesmurtozalikhon - kaggle.com/
datasets/ , at Kaggle; found in the referencesorvile - kaggle.com/
datasets/ , at Kaggle; found in the referencestrainingdatapro
Data availability statement
The paper has a data availability statement. Its license (CC BY-NC-ND) does not allow reproducing it here; in short, from what the harvester recognized in it:
- no repository, dataset or request procedure was recognized in it
Read it in the paper: doi.org/10.1038/s41598-026-50158-1.
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 1, 30 September 2026: the first record
Recorded: type, language, journal, volume, issue, pages, dates, 3 authors, 13 keywords, 18 references.
Cite
This paper
Esfahani, A. N., Jalili, A., & Sajedi, H. (2026). NeXtSwin-X: dual-branch cross-attention fusion of ConvNeXt and swin transformer for accurate brain tumor classification from MRI and CT. Scientific reports, 16(1), 19959. https://
BibTeX
@article{esfahani2026nex
author = {Esfahani, Arash Nasr and Jalili, Amirreza and Sajedi, Hedieh},
title = {{NeXtSwin-X: dual-branch cross-attention fusion of ConvNeXt and swin transformer for accurate brain tumor classification from MRI and CT}},
journal = {Scientific reports},
year = {2026},
month = apr,
volume = {16},
number = {1},
pages = {19959},
publisher = {Nature Publishing Group},
issn = {2045-2322},
doi = {10.1038/
url = {https://
pmid = {42034796},
pmcid = {PMC13319430}
}
RIS
TY - JOUR
AU - Esfahani, Arash Nasr
AU - Jalili, Amirreza
AU - Sajedi, Hedieh
TI - NeXtSwin-X: dual-branch cross-attention fusion of ConvNeXt and swin transformer for accurate brain tumor classification from MRI and CT
T2 - Scientific reports
J2 - Sci Rep
PY - 2026
DA - 2026/
VL - 16
IS - 1
SP - 19959
SN - 2045-2322
PB - Nature Publishing Group
DO - 10.1038/
UR - https://
LA - en
ER -
CSL-JSON
{
"id": "10.1038/
"type": "article-journal",
"title": "NeXtSwin-X: dual-branch cross-attention fusion of ConvNeXt and swin transformer for accurate brain tumor classification from MRI and CT",
"container-title": "Scientific reports",
"author": [
{
"family": "Esfahani",
"given": "Arash Nasr"
},
{
"family": "Jalili",
"given": "Amirreza"
},
{
"family": "Sajedi",
"given": "Hedieh"
}
],
"container-title-short":
"volume": "16",
"issue": "1",
"page": "19959",
"DOI": "10.1038/
"PMID": "42034796",
"PMCID": "PMC13319430",
"ISSN": "2045-2322",
"publisher": "Nature Publishing Group",
"URL": "https://
"language": "en",
"issued": {
"date-parts": [
[
2026,
4,
25
]
]
}
}
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.3390/jimaging12060233 [code]
- Brain Tumor Classification in MRI Images Using Combined Transfer Learning and Convolutional Neural Networks.Journal: Journal of imagingIn common: seaborn, scikit-learn, pandas, 2 other tools, kaggle.com/datasets/ahmedhamada0, structural MRI / diffusion, other condition
- [2] doi:10.3389/fncom.2026.1798561
- Bridging modalities: a deep learning framework for brain tumor classification via CT-MRI integration and model fusion.Journal: Frontiers in computational neuroscienceIn common: kaggle.com/datasets/murtozalikhon, other, structural MRI / diffusion, other condition, 1 reference
- [3] doi:10.1038/s41598-026-45675-y [code]
- Multi-class classification of brain tumor using a ResNet101 backbone integrated with multi-scale deformable attention module and advanced data augmentations.Journal: Scientific reportsIn common: PyTorch, seaborn, scikit-learn, 3 other tools, structural MRI / diffusion, other condition, 1 reference
- [4] doi:10.21037/qims-2026-0792 [code]
- An nnU-Net-based framework with adaptive feature representation for 3D brain tumor segmentation.Journal: Quantitative imaging in medicine and surgeryIn common: PyTorch, seaborn, scikit-learn, 3 other tools, structural MRI / diffusion, other condition, 1 reference
- [5] doi:10.3389/frai.2026.1771088 [code]
- Few-shot deployment of pretrained MRI transformers in brain imaging tasks.Journal: Frontiers in artificial intelligenceIn common: PyTorch, seaborn, scikit-learn, 3 other tools, structural MRI / diffusion, 1 reference
- [6] doi:10.3389/fmed.2026.1875760 [code]
- Adaptive multi-stage domain unlearning for white-matter lesion segmentation.Journal: Frontiers in medicineIn common: PyTorch, seaborn, scikit-learn, 3 other tools, structural MRI / diffusion, 1 reference
- [7] doi:10.1186/s40708-026-00316-y [code]
- Generalizable and explainable deep learning for brain MRI: a multi-cohort evaluation of 3D architectures for age and sex prediction.Journal: Brain informaticsIn common: PyTorch, seaborn, scikit-learn, 3 other tools, structural MRI / diffusion, 1 reference
- [8] doi:10.1038/s41746-026-02713-3 [code]
- Learning like a radiologist: a medical vision-language model for radiological image analysis via curriculum learning.Journal: NPJ digital medicineIn common: PyTorch, pandas, NumPy, kaggle.com/datasets/ahmedhamada0
- [9] doi:10.1186/s12938-026-01555-0 [code]
- Incorporating normal periventricular changes for enhanced pathological white matter hyperintensity segmentation: on multiclass deep learning approaches.Journal: Biomedical engineering onlineIn common: seaborn, scikit-learn, pandas, 2 other tools, structural MRI / diffusion, 1 reference
- [10] doi:10.3389/fmed.2026.1810860
- Lightweight deep learning for medical imaging using MobileNetV2-based brain pathology classification with Grad-CAM interpretability.Journal: Frontiers in medicineIn common: kaggle.com/datasets/trainingdatapro, other
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.
Claim this paper
Correct its record
Say what each link of this record is, remove the ones that are not the paper's, add the ones that are missing. The correction becomes a new version of the record, in its Versions section.
Validate its tracing map
You validate the map as this page shows it: 1 repository of the authors' code, each at its verified commit and with its license, 6 scripts, and 8 matches between paragraphs and code (see the Code and Map sections). It then receives a DOI on Zenodo, with you (your ORCID iD) and OSCR as its creators; the code itself is not deposited.
The map's fingerprint: sha256:96bd0745866debbf…
Add the badge to its README
The badge links the code to this page. Copy one of these into the README of the paper's code: only you decide where it goes, and nothing is changed for you.
Markdown
[, paste the snippet at the top, then “Commit changes…” and, to review it first, “Create a new branch and start a pull request”. You open the pull request; OSCR asks for no permission.
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: questions and error reports about this paper and its code, from signed-in readers and its authors. It opens with sign-in.
Reproductions: reports from readers who ran the authors' code: what they reproduced, with which environment, commit and data. It opens with sign-in.
Activity: what happens around this paper: new versions of its record, its map's validation, discussions and reproductions. It opens with sign-in.
