WorksComputer Science
Efficient Self-Supervised Adaptation of 3D Abdominal Vision-Language Model for Institution-Specific HCC Classification via Full Fine-Tuning and PEFT
Abstract
Medical vision-language models (VLMs) capture cross-modal relationships between image and text, yet their adaptation to institution-specific clinical tasks remains underexplored. In this study, we fine-tuned a pretrained 3D medical VLM for hepatocellular carcinoma (HCC) classification using paired abdominal CT scans and radiology reports from a different institution with acquisition characteristics that differ from the model's original pretraining corpus. We compared two adaptation strategies: full fine-tuning and parameter-efficient fine-tuning (PEFT), motivated by the common use of PEFT to reduce computational cost and enable adaptation under limited-data constraints. Both approaches achieve strong downstream HCC classification performance despite the cross-institutional domain shift, with PEFT reaching an AUC of 0.79 and F1 of 0.70, and full fine-tuning achieving an AUC of 0.82 and F1 of 0.71. Although these results remain below the performance reported by supervised HCC classification approaches, our method achieves improvements over the pretrained model through CT-report contrastive learning without requiring lesion-level annotations or HCC classification labels as training targets. Full fine-tuning converges rapidly but overfits within a few epochs, whereas PEFT (ConvLoRA for the image encoder and LoRA for the text encoder) attains comparable performance while updating approximately 1% of the model parameters, although requiring more training steps. We also examine the role of contrastive temperature, observing that temperature initialization significantly affects classification performance. This study demonstrates that a 3D medical VLM can be efficiently adapted to institution-specific HCC classification using self-supervised CT-report contrastive learning, while highlighting the practical trade-offs between full fine-tuning and parameter-efficient fine-tuning.
This author revision reports corrected HCC classification results after revising pre-processing to address slice-count-related shortcuts associated with zero-padding. Although performance is lower than originally reported in the published MIDL 2026 paper ([10]), the main findings remain supported: temperature initialization influences adaptation, and PEFT better retains external-task performance than full fine-tuning at best setting, consistent with less forgetting.
© 2026 CC-BY 4.0, F.P. Kartika, C.-Y. Ma, Y.-J. Lin, C.-T. Cheng & K.-F. Chen.
Introduction
Liver cancer remains a major global health challenge, ranked as the sixth most commonly diagnosed cancer and the third leading cause of cancer-related mortality, with more than 850,000 new cases and more than 750,000 deaths recorded in 2022 [3]. This burden is dominated by Hepatocellular Carcinoma (HCC), which accounts for approximately 80% of primary liver cancer [16]. New cases and mortality are projected to rise by 31%-98% across different regions by 2045 [13]. These trends signal an escalating global health burden, with implications for prevention, early detection, and resource allocation in both high and low-income regions.
A recent systematic review on deep learning methods for HCC [22] has shown that conventional deep learning approaches mostly rely on lesion-level annotations or tumor segmentation masks via supervised training, which require substantial radiologist effort and are difficult to scale across institutions. Many existing studies depend on manually outlining the liver lesions across multiple CT phases, making large-scale supervised training costly and limiting the applicability of such models in resource-constrained clinical environments. These requirements motivate the need for approaches that leverage a more efficient form of supervision, such as paired CT scans and radiology reports, which are already available in most routine clinical workflows.
Vision-language models (VLMs) have emerged as a promising paradigm for medical imaging, offering strong generalization without the need for extensive task-specific labels. The CLIP [15] framework demonstrated the effectiveness of contrastive image–text alignment, inspiring a wave of radiology-specific VLMs. However, although early applications of vision-language models in the medical domain, such as ConVIRT [25], GLoRIA [9] and MedCLIP [21] demonstrated the feasibility of aligning visual features with textual descriptions, they were largely driven by 2D frameworks trained on radiographs paired with short reports at sentence-level, despite the inherently 3D and volumetric nature of abdominal CT imaging. In recent years, the field has since progressed toward 3D VLMs capable of processing MRI, CT, and PET volumes. Models like CT-CLIP [7], HLIP [26], and fVLM [17] have demonstrated promising improvements in spatial understanding and clinical relevance. Nevertheless, the computational cost of training and fine-tuning these architectures, coupled with the substantial dataset requirements, remains a major challenge for broad deployment. The recently proposed Merlin [2] model addresses several of these limitations by processing complete 3D abdominal CT volumes and leveraging both structured EHR data and unstructured radiology reports for pretraining.
Despite these advances, adapting large medical VLMs to institution-specific downstream tasks remains challenging. Full fine-tuning of 3D VLMs is computationally expensive due to the large size of CT volumes and long radiology reports, and can lead to overfitting, causing the model to fail to adapt to institution-specific data. To address these challenges, we explored parameter-efficient fine-tuning (PEFT) as a lightweight and data-efficient strategy for adapting a pretrained 3D VLM to HCC classification. This choice is motivated by realistic clinical and academic constraints, in which memory, compute, and deployment limitations often preclude extensive retraining of large 3D models where PEFT provides a bounded and stable adaptation strategy that preserves pretrained multimodal representations while enabling effective domain adaptation. Full fine-tuning is included as a baseline to contextualize the performance and resource trade-offs of PEFT under identical experimental conditions In this work, we applied ConvLoRA [1] on the image encoder and LoRA [8] on the text encoder updating only a small fraction of model parameters. We evaluated the effect of temperature initialization, classification performance, and activation heatmaps, examining how PEFT compares to full fine-tuning under limited-data conditions. Although prior medical VLMs adapt CLIP-style [15] temperature initialization, the effect of temperature itself has been largely overlooked. Both the 2D radiology VLMs and the recent 3D models mentioned above typically inherit this temperature setting without further analysis. To our knowledge, no existing 3D medical VLM study examines how temperature affects adaptation behavior on downstream classification performance, even though temperature governs how strongly the contrastive loss penalizes hard negative samples by scaling their contribution to the contrastive gradients [20]. Our contributions include:
We demonstrated that competitive HCC classification performance can be achieved without lesion segmentation labels or extensive computational resources, using self-supervised contrastive learning and PEFT of a 3D VLM on institutional CT-report pairs
We evaluated the performance of PEFT-based adaptation against full fine-tuning, quantifying the trade-offs between predictive accuracy, training stability, and efficiency in HCC classification task.
We present the first analysis of contrastive temperature in 3D medical VLM adaptation, showing how temperature reshapes embedding structure, class separability, and downstream HCC classification performance.
We release all our trained models and code, enabling full reproducibility and supporting further research on efficient 3D VLM adaptation.
This work highlights a practical and computationally efficient path closer toward hospital-specific deployment of medical foundation models under real-world data constraints. Code available at: https://github.com/fbrynpk/HCC-Merlin
Materials and Methods
Dataset
This study uses an internal, institution-specific abdominal CT dataset containing contrast-enhanced multiphase abdominal CT scans and corresponding radiology reports. The full dataset comprises four contrast phases with the following distribution: non-contrast (24.5%), arterial phase (25.4%), portal venous (26.8%), and delayed phase (23.3%). For all experiments, we restrict our analysis to the portal venous (PV) phase, as Merlin [2] was pretrained predominantly on PV-phase abdominal CT scans, making PV inputs most aligned with its pretraining distribution and reducing cross-phase domain shift allowing a more controlled evaluation to better assess adaptation behavior. Additionally, preliminary experiments incorporating multi-phase inputs did not yield consistent performance improvements in our setting. As such, and to avoid introducing additional confounding factors, we restrict the present study to PV-phase imaging. Comprehensive multi-phase modeling is left for future work. Furthermore, PV-phase scans are also the most consistently available in our institutional cohort.
After filtering the full dataset to PV-phase studies, the resulting cohort contains 3,599 scans with 1,713 HCC-positive and 1,886 negative cases. The negative group consists of patients without hepatocellular carcinoma and does not represent a healthy control population. Negative cases may exhibit chronic liver disease (e.g., fatty liver or chronic hepatitis), benign hepatic findings such as cysts, or other non-malignant abdominal findings commonly encountered in routine clinical imaging. No primary liver tumors other than HCC are included in the dataset. This heterogeneous composition reflects realistic clinical screening conditions and reduces the likelihood of trivial separation between positive and negative cases. Importantly, HCC labels originated from the dataset and are not extracted from the radiology reports. These labels are solely used on the validation and test sets for metrics calculation.
| Split | Patients | Scans | Slices |
| Train | 1,276 | 2,124 | 90,620 |
| Validation | 438 | 799 | 33,836 |
| Test | 430 | 676 | 28,799 |
| Total | 2,144 | 3,599 | 153,255 |
Table 1. Portal Venous Phase Dataset Distribution (HCC vs Negative)
Dataset Splits We split the dataset at the patient level into training, validation and test sets using a 60% / 20% / 20% allocation. Patient-level splitting ensures that no individual appears in more than one subset, preventing data leakage from patients with multiple visits or repeated scans. Because patients contributed varying numbers of studies, phases, and time points, the resulting sample-level proportions deviated slightly from the target 60/20/20 split. Phases and CT scans distribution are provided in Appendix A
Dataset Preprocessing
Image Preprocessing: All CT volumes were preprocessed similarly to the original Merlin [2] pipeline. To mitigate shortcuts associated with slice-count imbalance, a cropped version of the dataset that preserved the entire liver was used instead. Each scan was reoriented to RAS+ convention, resampled the in-plane axial images to 1.5 mm resolution, and out-of-plane slice thickness to 3.0 mm spacing using bilinear interpolation. We then mapped the Hounsfield unit (HU) range -1000:1000 to the range 0:1, clipping values that fall outside of this range. Finally, we pad and center-crop to pixels in-plane and interpolate to 160 slices out-of-plane instead of zero-padding.
Report Preprocessing: Radiology reports in our dataset are unstructured free text. To obtain consistent, structured input for the text encoder, we employed Qwen3-8B (Team, 2025) to segment each report into Clinical Information, Findings, and Impression sections. We then further decomposed the Findings, and Impression sections into anatomical subregions using the same prompting strategy based on Merlin’s [2] original pretraining. This ensures that the textual granularity and anatomical alignment remain consistent with the model’s pretraining regime. The exact prompt used for extraction and segmentation is provided in Appendix B.
Base Model (Merlin)
Merlin [2] is a 3D vision-language model pretrained specifically for abdominal imaging. The model leverages paired abdominal CT volumes, structured electronic health record (EHR) data, and unstructured radiology reports to learn joint visual-text representations. Its pretraining dataset consists of over 6 million CT slices derived from 15,331 abdominal CT studies, alongside more than 1.8 million EHR codes and over 6 million tokens of radiology report text. For the image encoder, it employs an inflated ResNet-152 [4], unlike most 3D VLMs that rely on Vision Transformers [5], which typically demand substantial memory and multi-GPU environments. This convolutional backbone offers a more computationally efficient alternative. This design choice enables full 3D volumetric training on a comparatively modest hardware using only a single A6000 GPU, significantly reducing the resource burden associated with 3D VLMs pretraining. For the text encoder, it uses a Clinical Longformer [11] selected for its ability to process long radiology reports that exceed the context length of standard transformer architectures.
Adaptation Setup
Full Fine-Tuning:
In this setting, all parameters of both the image encoder and text encoder are updated. During fine-tuning, we alternate between the Findings and Impression sections with the anatomical decomposed section per steps following Merlin [2] pretraining strategy. Full fine-tuning enables the model to fully adapt to the target HCC classification task but requires significantly more computational resources and carries a higher risk of overfitting with a limited dataset. This baseline reflects the conventional approach to domain adaptation but is computationally expensive and less suitable under limited-data conditions.
Parameter-Efficient Fine-Tuning (PEFT): ConvLoRA and LoRA:
To reduce the computational and data demands, we apply parameter-efficient fine-tuning (PEFT) by introducing lightweight adapter modules into the pretrained model while keeping the backbone frozen, except for the final projection layers of the text and image encoders, as we found that freezing these layers prevented the VLM from adapting to the new task effectively.
LoRA - Text Encoder We first adapt the transformer-based text encoder using LoRA [8], applied to the query, key, and value projection matrices within each multihead self-attention layer. Given a pretrained weight matrix , this introduces a low-rank residual update:
where and are low-rank factors with , and is a scaling factor. The pretrained weights remain frozen, and optimization occurs solely through and . This preserves the representational geometry of the pretrained transformer while allowing efficient adaptation with small parameter updates.
ConvLoRA - Image Encoder We then apply ConvLoRA [1] to 3D convolutional layers following the original formulation. Following LoRA, this method decomposes the update to a convolutional kernel into a low-rank residual, enabling task-specific adaptation with a minimal number of trainable parameters. For a given 3D convolutional layer with pretrained weights , ConvLoRA constrains the update by parameterizing it as:
where and are low-rank matrices with rank . Similar to LoRA, the original kernel is frozen, and only the low-rank factors and are learned during fine-tuning, ensuring that the update lies within a restricted low-dimensional subspace while preserving the pretrained convolutional structure. Following the original work, is initialized with random Gaussian weights and is initialized to zero, ensuring that adaptation begins from the pretrained representation. For more details on & , refer to Appendix § 9
Loss Function & Training Hyperparameters
We adopt a CLIP-style [15] self-supervised contrastive learning based on the InfoNCE loss [19] using CT scans and medical reports to align the image and text embeddings produced by the image and text encoders. Given a batch of 18 image-text pairs, the image features and text features are projected into a shared embedding space and normalized. Similarity is computed using the cosine similarity scaled by a learnable temperature . The symmetric InfoNCE loss is defined as:
where sim(, ) denotes cosine similarity. This loss encourages matched image-text pairs to remain close while pushing apart mismatched pairs. Full fine-tuning and PEFT were trained using identical optimization settings to enable direct comparison. Details on the hyperparameter settings are listed in Appendix § 9.
Zero-Shot Classification
To perform zero-shot classification in Figure 1, we follow the standard vision-language matching paradigm used in contrastive VLMs. The CT volume is encoded into a 3D image embedding, while each textual prompt representing either HCC or a negative description is encoded into the text embedding. Classification is then performed by computing the cosine similarity between the image embedding and each text embedding. The model assigns the class whose prompts yield the highest similarity score. Because cosine similarity directly reflects alignment in the joint embedding space, the model effectively selects the class description it believes best matches the input CT volume. The final prediction is obtained by aggregating similarities across multiple prompts per class.

Figure 1. Left: Overview of Self-Supervised Fine-Tuning Right: Overview of Zero-Shot Classification
Results
Zero-shot baseline
A recent systematic review of deep learning methods for HCC classification reported an average sensitivity of 0.89 (95% CI [0.87–0.91]), specificity of 0.90 (95% CI [0.87–0.92]), and AUC of 0.95 (95% CI [0.93–0.97]) across supervised approaches requiring lesion annotations or curated training labels [22]. Due to the lack of publicly available supervised deep learning models and datasets, our evaluation begins with zero-shot classification using pretrained vision-language models without liver-specific supervision. Following Merlin’s [2] comparison, we used BioMedCLIP [23], a VLM trained on 15 million 2D biomedical image-text pairs from scientific articles, which performs poorly in this 3D volumetric CT setting with an of 0.01 (95% CI [0.00–0.02]) and an AUC of 0.60 (95% CI [0.56-0.65]), correctly identifying only one HCC-positive case. The pretrained Merlin checkpoint achieves a substantially stronger baseline with an F1 of 0.61 (95% CI [0.57-0.65]) and an AUC of 0.65 (95% CI [0.61-0.69]). Although our adapted models do not reach the performance reported by supervised HCC classification approaches, our method achieves these results through self-supervised CT-report contrastive learning without requiring lesion-level ground-truth masks or HCC classification labels as training targets.
| Model | F1 | Recall | Precision | Accuracy | AUC |
| BiomedCLIP | 0.01 | 0.00 | 1.00* | 0.57 | 0.60 |
| Merlin (Base) | 0.61 | 0.79 | 0.50 | 0.57 | 0.65 |
| Merlin (PEFT) | 0.70 | 0.76 | 0.65 | 0.72 | 0.79 |
| Merlin (Full Fine-Tuned) | 0.71 | 0.75 | 0.68 | 0.74 | 0.82 |
Table 3. Result Comparison in Testing Set.
Fine-tuning vs PEFT
Both adaptation strategies improve downstream HCC classification performance, with full fine-tuning achieving slightly higher F1 and AUC than PEFT. However, PEFT achieves comparable performance while updating only approximately 1% of the model parameters and exhibiting more stable training (refer to Appendix § 10). Our best settings yield an F1 of 0.70 (95% CI [0.66-0.74]) for PEFT and an F1 of 0.71 (95% CI [0.67-0.75]) for full fine-tuning, both with an initial of 1.0. Both approaches also outperform BioMedCLIP fine-tuned using the same CT-report contrastive learning objective, which achieves an F1 of 0.62 (95% CI [0.58-0.67]). These results demonstrate that PEFT offers a computationally efficient alternative to full fine-tuning with only a marginal reduction in classification performance. An ablation study was conducted for the PEFT methods in Appendix § 11.
Effects of Contrastive Temperature
We further examined the effect of the contrastive temperature () used during adaptation. Temperature directly controls the sharpness of the similarity distribution in the contrastive softmax (Figure 12). Lower initial values produce sharper peaks, while higher initial values yield softer and more diffuse distributions. Empirically, from Figure 2 we observe that at the lowest initial temperature , the embeddings exhibit less stable clustering, with noticeable overlap between HCC and non-HCC samples. As the initial temperature increases, the embedding space becomes progressively more organized, samples form smoother and more coherent clusters, hence the separation between positive and negative classes becomes more pronounced. The highest initial temperature produces the most visible inter-class separation, reflecting improved embedding uniformity and reduced overfitting. These embeddings align with the training-validation loss behavior (Figure 6), indicating that higher initial temperatures promote more stable representation learning and better class separability. This behavior is further illustrated by the cosine similarity matrices in Appendix § 12.§ 2 and how contrastive temperature affects embedding shifts in Appendix § 12.§ 3.

Figure 2. Lower: Full Fine-tuned, Upper: PEFT Embeddings Shift of Each Temperature Initialization [0.07, 0.5, 1.0, 10.0]

Figure 6. Training-Validation Loss for each setup and temperature Orange: Training, Blue: Validation

Figure 12. Illustration of different contrastive temperatures () initialization affect the sharpness of the softmax similarity distribution.
Interpretability
To understand how adaptation alters the model’s decision process, we applied GradCAM ([6]) between a random CT scan and its positive negative prompts to visualize the spatial regions most influential to the HCC classification output. Figure 3 shows that in the zero-shot setting, the pretrained model exhibits diffuse attention that often fails to localize to the liver. After adaptation, both full fine-tuning and PEFT redirect the model’s focus toward anatomically relevant liver regions, producing strong and spatially concentrated responses. This shift indicates that adaptation not only improves classification accuracy but also refines the model’s spatial reasoning, suppressing irrelevant contextual cues and emphasizing clinically meaningful features.

Figure 3. GradCAM heatmaps before and after adaptation.
External Evaluation on VerSe Spine Fracture Dataset
To assess whether the adaptation methods under limited supervision leads to task-specific overfitting, we additionally evaluated the adapted models on the external VerSe ([12]) fracture dataset. VerSe consists of CT scans labeled for vertebral fractures and represents a different anatomical region and pathology compared to the target HCC task. Importantly, this dataset was not used for adaptation or hyperparameter tuning in this study. We evaluate the pretrained Merlin model, as well as models adapted via full fine-tuning and PEFT, using the same evaluation protocol. This analysis is intended as a supporting sanity check to assess the extent of performance degradation on an external task under limited data and compute settings, rather than as a claim of broad task generalization. The adapted model has shown comparable performance on best setting relative to the pretrained baseline, with PEFT generally retains more external-task performance than full fine-tuning, particularly at higher temperature initializations. At , where both methods achieve comparable HCC classification performance, PEFT retains an F1 of 0.65, compared to 0.31 for full fine-tuning, suggesting that PEFT may better preserve previously learned representations during institution-specific adaptation.
| Temp. Init. () | Method | F1 | Recall | Precision | Accuracy |
| Baseline | Baseline | 0.76 | 0.92 | 0.65 | 0.63 |
| 0.07 | PEFT | 0.00 | 0.00 | 0.00 | 0.35 |
| 0.07 | Full FT | 0.21 | 0.12 | 1.00 | 0.43 |
| 0.5 | PEFT | 0.45 | 0.35 | 0.64 | 0.45 |
| 0.5 | Full FT | 0.41 | 0.27 | 0.88 | 0.50 |
| 1.0 | PEFT | 0.65 | 0.62 | 0.70 | 0.58 |
| 1.0 | Full FT | 0.31 | 0.19 | 0.83 | 0.45 |
| 10.0 | PEFT | 0.67 | 0.73 | 0.61 | 0.53 |
| 10.0 | Full FT | 0.13 | 0.08 | 0.50 | 0.35 |
Table 5. External evaluation on the VerSe spine fracture dataset across Different Contrastive Temperatures (). Metrics reported: F1, Recall, Precision, Accuracy.
Discussion
This study demonstrates that a pretrained 3D medical vision-language model can be effectively adapted for hepatocellular carcinoma classification using only paired CT-report data without requiring pixel-level annotations or HCC classification labels as training targets. Both full fine-tuning and parameter-efficient fine-tuning improved the zero-shot performance of Merlin ([2]), with full fine-tuning achieving slightly higher classification performance while PEFT offered comparable results plus with lower memory requirements and better retention of external-task performance. By updating only low-rank adapter modules in the image and text encoders, GPU memory usage during training decreased from approximately 48 GB to 28 GB on a single NVIDIA A6000 GPU. This makes training feasible on modest hardware and enables larger effective batch sizes, highlighting that large 3D VLMs can be adapted efficiently even in resource-constrained environments.
To our knowledge, this is the first application of ConvLoRA ([1]) to the 3D convolutional image encoder of a medical VLM. Our analysis of contrastive temperature further highlights its important role in downstream performance. To our knowledge, this behavior has not been characterized in 3D medical VLM adaptation, underscoring temperature initialization as an underappreciated but critical hyperparameter for stable and effective domain transfer. Interpretability assessment using GradCAM (Gildenblat and contributors, [6]) showed that both adaptation strategies shifted Merlin’s attention toward anatomically relevant regions of the liver after training, particularly for the negative samples. This observation remained consistent after revising the preprocessing pipeline to address acquisition-related shortcuts, supporting the ability of paired CT-report self-supervision to guide spatial attention toward clinically meaningful structures without segmentation labels. During subsequent investigations, we identified differences in CT slice-count distributions between HCC-positive and HCC-negative cases, which could be exploited by the model under the original zero-padding preprocessing. To mitigate this issue, we revised the preprocessing pipeline by incorporating volume cropping to reduce slice-count imbalance and interpolation instead of zero-padding. We initially followed Merlin’s pretraining preprocessing (Blankemeier et al., [2]), including zero-padding to a fixed depth, and did not anticipate that this step could allow the model to exploit class-associated slice-count differences in our cohort. These findings highlight the need to reassess preprocessing inherited from pretraining for the target cohort, as differences in acquisition characteristics may introduce unintended shortcuts even when established pipelines are followed. Although corrected performance was lower than originally reported, the main findings remained supported. Despite these findings, several limitations should be acknowledged. Our study only evaluates one PEFT strategy (ConvLoRA (Aleem et al., [1]) and LoRA (Hu et al., [8])), though alternative adapters, prefix tuning, or hybrid update strategies may offer different trade-offs between accuracy and efficiency. Furthermore, our experiments focus exclusively on portal venous phase CT, whereas multi-phase abdominal imaging could provide complementary diagnostic information and may further improve performance. Finally, we address binary HCC classification, extending this framework to multi-class liver tumor classification would more closely reflect real-world diagnostic workflows and better evaluate the representational capacity of medical VLM adaptation.
Conclusion
We demonstrated a resource-efficient approach for adapting a pretrained 3D vision-language model to hepatocellular carcinoma classification using only paired CT-report data. Parameter-efficient fine-tuning achieved comparable performance to full fine-tuning while better retaining external-task performance and reducing almost half of the GPU memory requirements, demonstrating that large-scale VLM adaptation is feasible on a single GPU. Our analysis also shows that contrastive temperature substantially influences classification performance, with an initial achieving the strongest downstream performance among the evaluated settings. GradCAM visualization further suggests that adaptation shifts the model’s focus toward relevant liver regions, supporting the plausibility of the learned representations. These results highlight the promise of VLM-based adaptation for institution-specific clinical tasks without requiring lesion segmentation or extensive labeled training datasets. This work is not designed to demonstrate cross-institutional generalization. We aim to evaluate whether VLMs can be adapted efficiently in a single-institution scenario using limited hardware, consistent with real-world hospital constraints. Future work will investigate extensions to multi-phase CT and multi-class liver tumor classification.
Acknowledgments
This work was supported by the National Science and Technology Council in Taiwan (114-2314-B-182-013, 114-2321-B-182-001) and Chang Gung Memorial Hospital in Taiwan (CM-RPG2P0181, CMRPG2P0342, CMRPG2P0121).
CT Phases & Scan Distributions

Figure 4. Left: CT Phases Distribution. Right: HCC vs Negative Distribution
Text Preprocessing Prompts

Figure 5. Left: Clinical Information, Findings, and Impression Extraction Prompt. Right: Anatomical Decomposition Prompt
Figure 5. Illustrates the two prompt designs used for preprocessing: a clinical report extraction prompt that retrieves key sections [Clinical Information, Findings and Impression], and an anatomical-decomposition prompt that restructures the report into organ-level descriptions. Both prompts were implemented using a one-shot extraction strategy, where a single example output follows the instruction. We observed that one-shot prompting consistently produced more structured and reliable outputs than zero-shot prompting.
We also compared Qwen3-8B and Qwen3-14B (Team, 2025) for the extraction process. Despite the larger model size, Qwen3-14B produced outputs with greater variability in formatting and anatomical decomposition, whereas Qwen3-8B generated more stable and consistent extractions across all cases. For this reason, Qwen3-8B was adopted as the primary extractor. To assess whether the extracted text was suitable as supervision for contrastive fine-tuning, we evaluated the outputs using BERTScore [24] and the GREEN score [14]. The extraction achieved a BERTScore of 0.89 and 0.84 for Extraction and Decomposition, respectively and a GREEN score of 0.79 and 0.58, respectively, indicating that the generated narratives preserve the core semantic content and clinical fidelity of the original reports. These results demonstrate that the combination of one-shot prompting and Qwen3-8B provides sufficiently accurate and structured text for reliable supervision during VLM adaptation.
Training Hyperparameter
| Hyperparameter | Full Fine-Tuning | PEFT (ConvLoRA + LoRA) |
| Batch Size | 18 | 18 |
| Gradient Accumulation | 8 | 8 |
| Learning Rate | 1e-4 | 1e-3 |
| Optimizer | AdamW | AdamW |
| Epoch | 300 | 300 |
| Early Stopping Patience | 5 | 5 |
| Trainable Parameters | 271M | 3.24M |
| Temperature () | [0.07, 0.5, 1.0, 10.0] | [0.07, 0.5, 1.0, 10.0] |
Table 6. Training Hyperparameter
The learning rates were selected to match the optimization behavior expected for each adaptation strategy. For full fine-tuning, we use a learning rate of 1e-4, selected empirically to support stable optimization when updating all encoder parameters. Empirically, increasing the learning rate to 1e-3 caused the model to rapidly overfit and diverge from the pretrained representation before reaching optimal performance, so 1e-4 was retained as the only rate that produced stable convergence.
For PEFT, we evaluated both 1e-4 and 1e-3. While the lower rate achieved a similar final performance, it converged noticeably slower and offered no measurable benefit. Because only the adapter parameters and final projection layers are trainable and can tolerate faster updates, we selected 1e-3 as the more efficient and effective learning rate for PEFT.
We set the gradient accumulation step to 8 for both methods to achieve an effectively larger batch size, which is important for contrastive learning. Larger batch sizes provide more negative samples per update, yielding more stable similarity estimates and more reliable contrastive gradients. Fine-tuning without gradient accumulation resulted in noticeably less stable training dynamics. Accumulating gradients over 8 steps allowed us to maintain stable optimization while preserving memory usage.
Other optimization settings followed the original VLM pretraining setup. We use the AdamW optimizer with . A cosine learning rate scheduler is applied with decay to zero over 300 epochs. Early stopping with a patience set to 5 epochs based on validation F1 is used to prevent overfitting, the checkpoint with the lowest validation contrastive loss was used for evaluation. To reduce memory usage, gradient checkpointing for both the image and text encoders and training in FP16 mixed precision were also applied.
For LoRA and ConvLoRA settings in Table 2, we set LoRA with scaling factor () = 32, following common practice in VLM and transformer-based adapter literature where moderate ranks provide a strong balance between learning capacity and parameter efficiency. Preliminary experiments with lower ranks (e.g., or 8) eventually reached comparable performance, though with more training time and exhibited slower convergence, offering no practical benefit under our compute constraints, while higher ranks (e.g., ) increased memory usage without noticeable performance gains. For ConvLoRA, we adopt both & as proposed in the original ConvLoRA formulation. We empirically evaluated higher ConvLoRA ranks () and observed no consistent performance improvements over , while incurring additional memory overhead. These settings therefore represent an effective trade-off between stability, adaptation capacity, and parameter efficiency.
| Component | LoRA | ConVLoRA |
| Injection layers | , , projections in all [12] layers | [Layer1, Layer2, Layer3, Layer4] |
| Rank () | 16 | 2 |
| Scaling factor () | 32 | 2 |
| Trainable params | 884,736 / 149,274,368 | 916,992 / 121,882,204 |
Table 2. LoRA & ConvLoRA Configuration
Full Fine-Tuning vs PEFT Training
The training-validation loss curves at Figure 6 highlight how contrastive temperature affects optimization stability. At a low temperature of , the model updates rapidly due to sharper similarity distributions and larger contrastive gradients. This accelerates early learning but also leads to rapid overfitting, reflected by the widening train-validation gap. As the temperature increases (e.g., and ), the gradients become smoother, slowing the update rate and reducing the tendency to memorize the training data, although the overfitting is still noticeably visible. At the highest temperature, , training progresses more gradually and exhibits the smallest divergence between training-validation loss, indicating improved robustness. Across all temperatures, PEFT consistently shows reduced overfitting compared to full fine-tuning, most prominently at . Because PEFT updates only a small set of low-rank adapter parameters, its effective capacity is lower, which inherently regularizes the optimization process. This results in more stable training dynamics.
Ablation Study
All ablation experiments from Table 7 were performed on the validation set with the best PEFT settings highlighted from Table 4, with reported metrics corresponding to the best F1 score obtained within 10 epochs of training. We intentionally restrict each ablation run to 10 epochs to capture the early-phase adaptation behaviour of each PEFT component. In our full PEFT setting, performance increases rapidly in the first few epochs and then plateaus, with only marginal gain afterward. Each ablation isolates a single adaptation pathway:
| Temp. Init. () | Method | F1 | Recall | Prec. | Acc. | AUC | CosSim |
| 1.0 | BiomedCLIP | 0.62 | 0.66 | 0.59 | 0.66 | 0.74 | 0.49 |
| 0.07 | PEFT | 0.62 | 0.59 | 0.65 | 0.68 | 0.75 | 0.56 |
| 0.07 | Full FT | 0.59 | 0.52 | 0.68 | 0.69 | 0.77 | 0.51 |
| 0.5 | PEFT | 0.63 | 0.60 | 0.66 | 0.69 | 0.77 | 0.66 |
| 0.5 | Full FT | 0.67 | 0.68 | 0.67 | 0.71 | 0.80 | 0.61 |
| 1.0 | PEFT | 0.70 | 0.76 | 0.65 | 0.72 | 0.79 | 0.69 |
| 1.0 | Full FT | 0.71 | 0.75 | 0.68 | 0.74 | 0.82 | 0.69 |
| 10.0 | PEFT | 0.66 | 0.68 | 0.63 | 0.69 | 0.76 | 0.76 |
| 10.0 | Full FT | 0.65 | 0.67 | 0.62 | 0.68 | 0.75 | 0.73 |
Table 4. Comparison of PEFT and Full Fine-Tuning across Different Contrastive Temperatures (). Metrics reported: F1, Recall, Precision, Accuracy, AUC, Mean Cosine Similarity between image-text pairs.
| Method | F1↑ | Recall↑ | Precision↑ | Accuracy↑ | Parameter (Trainable)↓ |
| Baseline | 0.69 | 0.78 | 0.62 | 0.63 | 271M (0) |
| Text Encoder | 0.75 | 0.87 | 0.66 | 0.69 | 271M (1.28M) |
| Image Encoder | 0.75 | 0.78 | 0.72 | 0.72 | 271M (1.96M) |
| Projection Layers | 0.72 | 0.73 | 0.70 | 0.70 | 271M (1.44M) |
| Full PEFT | 0.77 | 0.80 | 0.74 | 0.75 | 271M (3.24M) |
Table 7. Ablation Study on PEFT Methods
Text Encoder - LoRA applied only to the text encoder and unfrozen final text projection layer. Image encoder entirely frozen
Image Encoder - ConvLoRA applied only to the image encoder and unfrozen final image projection layer. Text encoder entirely frozen
Projection Layers - Only the final image and text projection layers are unfrozen. The rest of the backbone remains frozen.
Full PEFT - All PEFT components active. Represents the complete adaptation strategy and achieves the strongest performance.
This ablation design determines whether each component contributes unique signal or whether most of the performance gain arises from modifying a single pathway. The results in Table 7 show that each isolated component provides measurable improvement over the baseline, with Full PEFT achieving the highest classification metrics while remaining parameter-efficient.
Representation Analysis
Original VLM Embedding & Cosine Similarity Matrix
Before adaptation, the pretrained VLM exhibits limited separation between HCC and non-HCC cases in both the cosine-similarity matrix and embedding space. As shown in Figure 7, similarity scores are diffuse, and class structure is weak, reflecting the model’s lack of liver-specific supervision

Figure 7. Left: Original VLM Cosine Similarity Matrix Right: Original VLM Embedding Distribution
Cosine-Similarity Matrices
The cosine-similarity matrices in Figure 8 - Figure 11 illustrate how contrastive temperature shapes the structure of the similarity space. At low initial temperature , the model produces sharper but unstable similarity distributions, leading to a weaker separation between HCC and negative samples. As the initial temperature increases, the model becomes more confident in distinguishing positive from negative cases, resulting in clearer separation between different classes. However, very high initial temperatures (e.g. ) also cause intra-class similarity inflation: the model begins to treat all HCC reports

Figure 8. Cosine Similarity Matrices with initial temperatures [0.07].

Figure 11. Cosine Similarity Matrices with initial temperatures [10.0].

Figure 9. Cosine Similarity Matrices with initial temperatures [0.5].

Figure 10. Cosine Similarity Matrices with initial temperatures [1.0].
as highly similar to one another, regardless of their underlying clinical variation. This reflects the model learning coarse class-level semantics of ”HCC vs non-HCC” while losing the ability to differentiate among individual positive samples. Consequently, the cosine similarity values among distinct HCC reports increase, reflecting a collapse toward a single-class prototype rather than preserving finer distinctions. This phenomenon aligns with the embedding-space observations and highlights the trade-off between inter-class separability and intra-class granularity at high initial temperatures.
Softmax Temperature Distribution
Although temperature setting is inherited from CLIP-style Radford et al., [15] contrastive learning, it remains largely unexamined in existing 3D medical VLMs. Our results show that temperature initialization directly shapes adaptation dynamics by controlling the penalties applied to hard negative samples in the InfoNCE loss [19]. Lower temperatures initialization creates sharper similarity distributions that amplify these penalties, often leading to unstable updates and overfitting, whereas higher temperatures promote smoother gradients, more coherent embedding structure, and clearer class separation.
References
- [1]Sidra Aleem, Julia Dietlmeier, Eric Arazo, and Suzanne Little. Convlora and adabn based domain adaptation via self-training, 2024. URL https://arxiv.org/abs/2402.04964.
- [2]Louis Blankemeier, Joseph Paul Cohen, Ashwin Kumar, Dave Van Veen, Syed Jamal Safdar Gardezi, Magdalini Paschali, Zhihong Chen, Jean-Benoit Delbrouck, Eduardo Reis, Cesar Truyts, Christian Bluethgen, Malte Engmann Kjeldskov Jensen, Sophie Ostmeier, Maya Varma, Jeya Maria Jose Valanarasu, Zhongnan Fang, Zepeng Huo, Zaid Nabulsi, Diego Ardila, Wei-Hung Weng, Edson Amaro Junior, Neera Ahuja, Jason Fries, Nigam H. Shah, Andrew Johnston, Robert D. Boutin, Andrew Wentland, Curtis P. Langlotz, Jason Hom, Sergios Gatidis, and Akshay S. Chaudhari. Merlin: A vision language foundation model for 3d computed tomography, 2024. URL https://arxiv.org/abs/2406.06512.
- [3]Freddie Bray, Mathieu Laversanne, Hyuna Sung, Jacques Ferlay, Rebecca L. Siegel, Isabelle Soerjomataram, and Ahmedin Jemal. Global cancer statistics 2022: Globocan estimates of incidence and mortality worldwide for 36 cancers in 185 countries. CA: A Cancer Journal for Clinicians, 74(3):229–263, 2024. doi: https://doi.org/10.3322/caac.21834. URL https://acsjournals.onlinelibrary.wiley.com/doi/abs/10.3322/caac.21834.
- [4]Joao Carreira and Andrew Zisserman. Quo vadis, action recognition? a new model and the kinetics dataset, 2018. URL https://arxiv.org/abs/1705.07750.
- [5]Alexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn, Xiaohua Zhai, Thomas Unterthiner, Mostafa Dehghani, Matthias Minderer, Georg Heigold, Sylvain Gelly, Jakob Uszkoreit, and Neil Houlsby. An image is worth 16x16 words: Transformers for image recognition at scale, 2021. URL https://arxiv.org/abs/2010.11929.
- [6]Jacob Gildenblat and contributors. Pytorch library for cam methods. https://github.com/jacobgil/pytorch-grad-cam, 2021.
- [7]Ibrahim Ethem Hamamci, Sezgin Er, Chenyu Wang, Furkan Almas, Ayse Gulnihan Simsek, Sevval Nil Ersı̇ngun, Irem Dogan, Omer Faruk Durugol, Benjamin Hou, Suprosanna Shit, Weicheng Dai, Murong Xu, Hadrien Reynaud, Muhammed Furkan Dasdelen, Bastian Wittmann, Tamaz Amiranashvili, Enis Simsar, Mehmet Simsar, Emine Bensu Erdemir, Abdullah Alanbay, Anjany Sekuboyina, Berkan Lafci, Ahmet Kaplan, Zhiyong Lu, Malgorzata Polacin, Bernhard Kainz, Christian Bluethgen, Kayhan Batmanghelich, Mehmet Kemal Ozdemir, and Bjoern Menze. Developing generalist foundation models from a multimodal dataset for 3d computed tomography, 2025. URL https://arxiv.org/abs/2403.17834.
- [8]Edward J. Hu, Yelong Shen, Phillip Wallis, Zeyuan Allen-Zhu, Yuanzhi Li, Shean Wang, Lu Wang, and Weizhu Chen. Lora: Low-rank adaptation of large language models, 2021. URL https://arxiv.org/abs/2106.09685.
- [9]Shih-Cheng Huang, Liyue Shen, Matthew P. Lungren, and Serena Yeung. Gloria: A multimodal global-local representation learning framework for label-efficient medical image recognition. In 2021 IEEE/CVF International Conference on Computer Vision (ICCV), pages 3922–3931, 2021. doi: 10.1109/ICCV48922.2021.00391.DOI
- [10]Febryan Putra Kartika, Cheng-Yu Ma, Ying-Jia Lin, Chi-Tung Cheng, and Kuan-Fu Chen. Efficient self-supervised adaptation of 3d abdominal vision-language model for institution-specific hcc classification via full fine-tuning and peft. In Proceedings of The 9th International Conference on Medical Imaging with Deep Learning, volume 315 of Proceedings of Machine Learning Research, pages 3245–3269. PMLR, 2026. URL https://proceedings.mlr.press/v315/kartika26a.html.arxiv.org/abs/2611.22504
- [11]Yikuan Li, Ramsey M. Wehbe, Faraz S. Ahmad, Hanyin Wang, and Yuan Luo. Clinical-longformer and clinical-bibird: Transformers for long clinical sequences, 2022. URL https://arxiv.org/abs/2201.11838.
- [12]Maximilian T. Löffler, Anjany Sekuboyina, Alina Jacob, Anna-Lena Grau, Andreas Scharr, Malek El Husseini, Mareike Kallweit, Claus Zimmer, Thomas Baum, and Jan S. Kirschke. A vertebral segmentation dataset with fracture grading. Radiology: Artificial Intelligence, 2(4):e190138, 2020. doi: 10.1148/ryai.2020190138. URL https://doi.org/10.1148/ryai.2020190138. PMID: 33937831.
- [13]Ezequiel Mauro, Tiago de Castro, Marcus Zeitlhoefer, Max W. Sung, Augusto Villanueva, Vincenzo Mazzaferro, and Josep M. Llovet. Hepatocellular carcinoma: Epidemiology, diagnosis and treatment. JHEP Reports, 7(12):101571, 2025. ISSN 2589-5559. doi: https://doi.org/10.1016/j.jhepr.2025.101571. URL https://www.sciencedirect.com/science/article/pii/S2589555925002538.
- [14]Sophie Ostmeier, Justin Xu, Zhihong Chen, Maya Varma, Louis Blankemeier, Christian Bluethgen, Arne Edward Michalson Md, Michael Moseley, Curtis Langlotz, Akshay S Chaudhari, and Jean-Benoit Delbrouck. Green: Generative radiology report evaluation and error notation. In Findings of the Association for Computational Linguistics: EMNLP 2024, page 374–390. Association for Computational Linguistics, 2024. doi: 10.18653/v1/2024.findings-emnlp.21. URL http://dx.doi.org/10.18653/v1/2024.findings-emnlp.21.
- [15]Alec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh, Gabriel Goh, Sandhini Agarwal, Grish Satry, Amanda Askell, Pamela Mishkin, Jack Clark, Gretchen Krueger, and Ilya Sutskever. Learning transferable visual models from natural language supervision, 2021. URL https://arxiv.org/abs/2103.00020.
- [16]Harriet Rumgay, Jacques Ferlay, Catherine de Martel, Damien Georges, Amal Samy Ibrahim, Rongshou Zheng, Wenqiang Wei, Valery E.P.P. Lemmens, and Isabelle Soerjomataram. Global, regional and national burden of primary liver cancer by subtype. European Journal of Cancer, 161:108–118, 2022. ISSN 0959-8049. doi: https://doi.org/10.1016/j.ejca.2021.11.023. URL https://www.sciencedirect.com/science/article/pii/S0959804921012430.
- [17]Zhongyi Shui, Jianpeng Zhang, Weiwei Cao, Sinuo Wang, Ruizhe Guo, Le Lu, Lin Yang, Xianghua Ye, Tingbo Liang, Qi Zhang, and Ling Zhang. Large-scale and fine-grained vision-language pre-training for enhanced ct image understanding, 2025. URL https://arxiv.org/abs/2501.14548.
- [19]Aaron van den Oord, Yazhe Li, and Oriol Vinyals. Representation learning with contrastive predictive coding, 2019. URL https://arxiv.org/abs/1807.03748.
- [20]Feng Wang and Huaping Liu. Understanding the behaviour of contrastive loss, 2021. URL https://arxiv.org/abs/2012.09740.
- [21]Zifeng Wang, Zhenbang Wu, Dinesh Agarwal, and Jimeng Sun. MedCLIP: Contrastive learning from unpaired medical images and text. In Yoav Goldberg, Zornitsa Kozareva, and Yue Zhang, editors, Proceedings of the 2022 Conference on Empirical Methods in Natural Language Processing, pages 3876–3887, Abu Dhabi, United Arab Emirates, December 2022. Association for Computational Linguistics. doi: 10.18653/v1/2022.emnlp-main.256. URL https://aclanthology.org/2022.emnlp-main.256/.DOI
- [22]Qiuxia Wei, Nengren Tan, Shiyu Xiong, Wanrong Luo, Haiying Xia, and Baoming Luo. Deep learning methods in medical Image-Based hepatocellular carcinoma diagnosis: A systematic review and Meta-Analysis. Cancers (Basel), 15(23), December 2023.DOI
- [23]Sheng Zhang, Yanbo Xu, Naoto Usuyama, Hanwen Xu, Jaspreet Bagga, Robert Tinn, Sam Preston, Rajesh Rao, Mu Wei, Naveen Valluri, Cliff Wong, Andrea Tupini, Yu Wang, Matt Mazzola, Swadheen Shukla, Lars Liden, Jianfeng Gao, Angela Crabtree, Brian Piening, Carlo Bifulco, Matthew P. Lungren, Tristan Naumann, Sheng Wang, and Hoifung Poon. Biomedclip: a multimodal biomedical foundation model pretrained from fifteen million scientific image-text pairs, 2025. URL https://arxiv.org/abs/2303.00915.
- [24]Tianyi Zhang*, Varsha Kishore*, Felix Wu*, Kilian Q. Weinberger, and Yoav Artzi. BERTScore: Evaluating text generation with bert. In International Conference on Learning Representations, 2020. URL https://openreview.net/forum?id=SkeHuCVFDr.arxiv.org/abs/1904.09675
- [25]Yuhao Zhang, Hang Jiang, Yasuhide Miura, Christopher D. Manning, and Curtis P. Langlotz. Contrastive learning of medical visual representations from paired images and text. In Zachary Lipton, Rajesh Ranganath, Mark Sendak, Michael Sjoding, and Serena Yeung, editors, Proceedings of the 7th Machine Learning for Healthcare Conference, volume 182 of Proceedings of Machine Learning Research, pages 2–25. PMLR, 05–06 Aug 2022. URL https://proceedings.mlr.press/v182/zhang22a.html.
- [26]Chenhui Zhao, Yiwei Lyu, Asadur Chowdhury, Edward Harake, Akhil Kondepudi, Akshay Rao, Xinhai Hou, Honglak Lee, and Todd Hollon. Towards scalable language-image pre-training for 3d medical imaging, 2025. URL https://arxiv.org/abs/2505.21862.
AI tools statement
No AI-use declaration is available for this version in Valency.
The available record does not establish whether AI systems or models contributed to this work.