A new-born brain MRI image segmentation method and device and storage medium

CN122289284APending Publication Date: 2026-06-26THE THIRD AFFILIATED HOSPITAL OF GUANGZHOU MEDICAL UNIVERSITY (GUANGZHOU SEVERE MATERNAL TREATMENT CENTER GUANGZHOU ROUJI HOSPITAL)
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
THE THIRD AFFILIATED HOSPITAL OF GUANGZHOU MEDICAL UNIVERSITY (GUANGZHOU SEVERE MATERNAL TREATMENT CENTER GUANGZHOU ROUJI HOSPITAL)
Filing Date
2026-03-26
Publication Date
2026-06-26

AI Technical Summary

Technical Problem

Existing medical segmentation frameworks rely on fully supervised training and large amounts of labeled data for neonatal brain MRI segmentation, making it difficult to adapt to transfer between different datasets and vulnerable to changes during the rapid developmental stages of newborns.

Method used

The NeoPromptFormer segmentation model is adopted, combined with the PEFT-MAE module, Age-Prompt module and TQ-Decoder module. Through a parameter-efficient masking autoencoder pre-adaptation strategy and age condition cues, instantiated age cues are generated. Encoding adjustments and test optimizations without parameter tuning are then performed to achieve efficient adaptation to neonatal brain MRI segmentation.

Benefits of technology

Under limited supervised labeling, the NeoPromptFormer model can maintain robustness at different developmental stages, improve the robustness and adaptability of neonatal brain MRI segmentation, and enhance segmentation results in tissue and microlesion environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122289284A_ABST
    Figure CN122289284A_ABST
Patent Text Reader

Abstract

This application proposes a method, apparatus, and storage medium for segmenting neonatal brain MRI images. The method includes: acquiring and performing two-dimensional slicing on each neonatal brain MRI image in a sample dataset to obtain a processed sample dataset; constructing a NeoPromptFormer segmentation model based on a prompting-enabled visual backbone network, including a PEFT-MAE module, an Age-Prompt module, and a TQ-Decoder module; using the processed sample dataset to train the NeoPromptFormer segmentation model; acquiring and performing two-dimensional slicing on the neonatal brain MRI image to be tested to obtain a sliced ​​neonatal brain MRI image; and then inputting the sliced ​​neonatal brain MRI image into the NeoPromptFormer segmentation model for segmentation to obtain the final segmentation prediction result of the neonatal brain MRI image to be tested. This application can enhance the robustness of neonatal brain MRI segmentation in tissue and microlesion environments.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of medical image segmentation technology, and more particularly to a method, apparatus and storage medium for segmenting neonatal brain MRI images. Background Technology

[0002] Accurate segmentation of the neonatal brain in magnetic resonance imaging (MRI) is a prerequisite for conducting population-scale connectomics studies and quantitative neurodevelopmental analysis. Compared with adult MRI, neonatal scans present challenges such as rapid changes in anatomical structures, lower tissue contrast and frequent inversion, as well as significant differences between different scanners, protocols, and postmenstrual age (PMA).

[0003] While modern medical segmentation frameworks (such as U-Net, 3DU-Net, V-Net, nnU-Net, and UNETR) are powerful general-purpose benchmark models, they typically rely on fully supervised training and large amounts of labeled data, and often require expensive retraining or fine-tuning to transfer between different datasets.

[0004] Therefore, segmenting neonatal brain MRI using modern medical segmentation frameworks (i.e., fully supervised segmentation methods) is relatively fragile when there are limited labels and changes in age / protocol. Summary of the Invention

[0005] This application provides a method, apparatus, and storage medium for segmenting neonatal brain MRI images to address the problems existing in related technologies. The technical solution is as follows: In a first aspect, embodiments of this application provide a method for segmenting neonatal brain MRI images, including: Obtain a sample dataset, which includes multiple neonatal brain MRI images, wherein each neonatal brain MRI image contains its corresponding label mapping map, and the label mapping map contains the neonatal postmenopausal age (PMA). Each neonatal brain MRI image in the sample dataset is subjected to two-dimensional slicing to obtain the processed sample dataset; Based on a promptable visual backbone network, a NeoPromptFormer segmentation model is constructed. This model includes a PEFT-MAE module, an Age-Prompt module, and a TQ-Decoder module. The segmentation prediction process of the NeoPromptFormer model is as follows: The PEFT-MAE module employs a parameter-efficient masked autoencoder pre-adaptation strategy to fine-tune the encoding process of the input image based on the instantiated age prompts output by the Age-Prompt module. The Age-Prompt module dynamically generates instantiated age prompts from a learnable age conditional prompt library based on the PMA of the input image and transmits these prompts to the PEFT-MAE module for encoding adjustment. The TQ-Decoder module generates an initial segmentation prediction result for the input image based on the output features of the PEFT-MAE module. Under differentiable dissection prior conditions, the initial segmentation prediction result is tested and optimized without parameter tuning based on the prompts or query variables of the input image, and the optimized final segmentation prediction result is output. The NeoPromptFormer segmentation model is trained using the processed sample dataset. Obtain MRI images of the newborn's brain; The neonatal brain MRI image to be tested is processed into two-dimensional slices to obtain a neonatal brain MRI image after two-dimensional slice processing. The neonatal brain MRI image after two-dimensional slicing is input into the NeoPromptFormer segmentation model for segmentation processing to obtain the final segmentation prediction result of the neonatal brain MRI image to be tested.

[0006] In one implementation, each of the neonatal brain MRI images in the sample dataset is subjected to two-dimensional slicing to obtain a processed sample dataset comprising: Two-dimensional slices are made for each neonatal brain MRI image in the sample dataset to obtain multiple slices corresponding to each neonatal brain MRI image; By stacking adjacent slices from the plurality of slices, each newborn brain MRI image is obtained after two-dimensional slicing. Based on each neonatal brain MRI image after two-dimensional slicing, the processed sample dataset is obtained.

[0007] In one implementation, the PEFT-MAE module includes a lightweight modality adapter, a LoRA adapter, and a pre-trained ViT image encoder and MAE decoder from the SAM model, where LoRA refers to low-rank adaptation. The PEFT-MAE module employs a parameter-efficient masked autoencoder pre-adaptation strategy, and the parameter-efficient fine-tuning of the encoding process of the input image based on the instantiated age prompts output by the Age-Prompt module includes: The input image is mapped to the basic visual backbone network of the ViT image encoder using the lightweight modal adapter. The ViT image encoder performs feature encoding on the input image based on the instantiated age prompt words output by the Age-Prompt module; The LoRA adapter is used to adaptively adjust each attention projection matrix in the selected basic visual backbone network of the ViT image encoder; The MAE decoder employs a parameter-efficient mask autoencoding pre-adaptation strategy to perform parameter fine-tuning on the encoding process of the ViT image encoding.

[0008] In one implementation, the parameter-efficient mask autoencoding pre-adaptation strategy employed by the MAE decoder to perform parameter-efficient fine-tuning of the ViT image encoding process includes: For each slice in the input image, a portion of the image block in each slice is randomly masked using the MAE decoder; The masked image blocks in each slice are reconstructed using the MAE decoder. During this process, the loss between the reconstructed image blocks and the original image blocks in each slice is minimized. Only the parameters of the lightweight modal adapter, the instantiated age cue, and the LoRA adapter are updated. After pre-adaptation, only the PEFT parameters adapted during the encoding process of the ViT image encoding are retained. PEFT refers to parameter efficient fine-tuning.

[0009] In one implementation, the Age-Prompt module dynamically generates instantiated age prompt words from a learnable age conditional prompt library based on the PMA of the input image, and transmits the instantiated age prompt words to the PEFT-MAE module for encoding adjustment, including: The PEFT-MAE module predefines M basic age prompt word sets corresponding to each basic visual backbone network; The Age-Prompt module is used to map the PMA of the input image into an M-dimensional hybrid weight vector through a multilayer perceptron (MLP). Then, the M basic age prompt word sets are weighted and summed according to the hybrid weight vector to obtain the instantiated age prompt word. The Age-Prompt module is used to transmit the instantiated age prompt word to the PEFT-MAE module for encoding adjustment.

[0010] In one embodiment, the method includes: The Age-Prompt module is used to apply smoothness regularization constraints to adjacent age prompts in the instantiated age prompts to avoid discontinuous age prompt switching and to encourage developmental continuity.

[0011] In one implementation, the TQ-Decoder module generates an initial segmentation prediction result for the input image based on the output features of the PEFT-MAE module. Then, under differentiable anatomical prior conditions, the initial segmentation prediction result is tested and optimized without parameter tuning based on the cue or query variables of the input image. The optimized final segmentation prediction result includes: The TQ-Decoder module uses K learnable category queries and performs cross-attention decoding with the instantiated age prompt words through a Transformer decoder to generate K refined category queries. The TQ-Decoder module is used to generate an initial segmentation prediction result for the input image based on the K refined category queries; During the model inference phase, the TQ-Decoder module is used to perform small residual updates on the category query offset, and the weight of the instantiated age prompt is fixed to the output of the PEFT-MAE module. Then, the target supervision function is used to supervise the initial segmentation prediction result, and the optimized final segmentation prediction result is output. The category query offset is the difference between each learnable category query and its corresponding refined category query.

[0012] Secondly, embodiments of this application also provide a neonatal brain MRI image segmentation device, comprising: The first data receiving unit is used to acquire a sample dataset, which includes multiple neonatal brain MRI images, wherein each neonatal brain MRI image contains its corresponding label mapping map, and the label mapping map contains the neonatal postmenopausal age (PMA). The first preprocessing unit is used to perform two-dimensional slicing on each of the neonatal brain MRI images in the sample dataset to obtain the processed sample dataset. The model building unit is used to construct the NeoPromptFormer segmentation model based on a promptable visual backbone network. The NeoPromptFormer segmentation model includes a PEFT-MAE module, an Age-Prompt module, and a TQ-Decoder module. The segmentation prediction process of the NeoPromptFormer segmentation model is as follows: The PEFT-MAE module employs a parameter-efficient masked autoencoder pre-adaptation strategy; the encoding process of the input image based on the instantiated age prompts output by the Age-Prompt module is parameterized. Efficient fine-tuning: The Age-Prompt module dynamically generates instantiated age prompts from a learnable age conditional prompt library based on the PMA of the input image, and transmits the instantiated age prompts to the PEFT-MAE module for encoding adjustment; the TQ-Decoder module generates an initial segmentation prediction result for the input image based on the output features of the PEFT-MAE module, and performs parameter-free test optimization on the initial segmentation prediction result for the prompts or query variables of the input image under differentiable dissection prior conditions, and outputs the optimized final segmentation prediction result; The model training unit is used to train the NeoPromptFormer segmentation model using the processed sample dataset to obtain a trained NeoPromptFormer segmentation model. The second data receiving unit is used to acquire MRI images of the newborn's brain. The second preprocessing unit is used to perform two-dimensional slicing on the neonatal brain MRI image to be tested, so as to obtain a neonatal brain MRI image after two-dimensional slicing. The model prediction unit is used to input the neonatal brain MRI image after two-dimensional slicing into the NeoPromptFormer segmentation model for segmentation processing, and obtain the final segmentation prediction result of the neonatal brain MRI image to be tested.

[0013] Thirdly, embodiments of this application also provide a computer device, which includes: a memory and a processor, wherein the memory stores instructions, the instructions are loaded and executed by the processor to implement the methods in any of the above embodiments, wherein the memory and the processor communicate with each other through an internal connection path.

[0014] Fourthly, embodiments of this application also provide a computer-readable storage medium storing a computer program that, when run on a computer, implements the methods in any of the above-described embodiments.

[0015] The advantages or beneficial effects of the above technical solutions include at least the following: This application provides an efficient and age-aware adaptive strategy for neonatal brain MRI segmentation, which utilizes prior knowledge from a base model and efficiently adapts to neonatal brain MRI under limited supervised labeling conditions, while maintaining robustness to changes at different developmental stages and different segmentation tasks, thereby enhancing the robustness of neonatal brain MRI segmentation in tissue and microlesion environments.

[0016] The above overview is for illustrative purposes only and is not intended to be limiting in any way. In addition to the illustrative aspects, embodiments, and features described above, further aspects, embodiments, and features of this application will become readily apparent from the accompanying drawings and the following detailed description. Attached Figure Description

[0017] In the accompanying drawings, unless otherwise specified, the same reference numerals throughout the various drawings denote the same or similar parts or elements. These drawings are not necessarily drawn to scale. It should be understood that these drawings depict only some embodiments disclosed in this application and should not be construed as limiting the scope of this application.

[0018] Figure 1 A flowchart illustrating a method for segmenting neonatal brain MRI images provided in this application embodiment; Figure 2 An example architecture diagram of a NeoPromptFormer segmentation model provided for embodiments of this application; Figure 3 An example diagram of Table 1 provided for an embodiment of this application; Figure 4 An example diagram of Table 2 provided for an embodiment of this application; Figure 5 An example diagram of Table 3 provided for an embodiment of this application; Figure 6 An example diagram of Table 4 provided for an embodiment of this application; Figure 7 An example diagram of Table 5 provided for an embodiment of this application; Figure 8 An example diagram of Table 6 provided for an embodiment of this application; Figure 9 An example diagram of Table 7 provided for an embodiment of this application; Figure 10 An example diagram of Table 8 provided for an embodiment of this application; Figure 11 An example diagram of Table 9 provided for an embodiment of this application; Figure 12 An example diagram of Table 10 provided for an embodiment of this application; Figure 13 A category query response diagram for TQ-Decoder module diagnosis provided in this application embodiment; Figure 14 An example diagram of an obfuscation matrix for TQ-Decoder module diagnosis provided in this application embodiment; Figure 15 An example diagram of the category Dice value for TQ-Decoder module diagnosis provided in this application embodiment; Figure 16 An example diagram illustrating the efficiency analysis of TQ-Decoder module diagnosing BOBs_real, provided in an embodiment of this application; Figure 17 An example diagram illustrating a qualitative comparison of preserved BOBs multi-tissue sections and multi-channel structures provided for embodiments of this application; Figure 18 An example diagram of a BONBID-HIE qualitative analysis panel generated based on retained test data, provided for embodiments of this application; Figure 19 An example diagram of a BONBID-HIE qualitative analysis panel generated based on retained test data, provided for embodiments of this application; Figure 20 An example diagram of PEFT-MAE evidence of a real preserved slice provided for an embodiment of this application; Figure 21 An example diagram of TTA evidence for a real BONBID-HIE test slice provided for an embodiment of this application; Figure 22 An example diagram of BONBID-HIE lesion analysis with preserved test data provided in this application embodiment; Figure 23 A structural block diagram of a neonatal brain MRI image segmentation device provided in this application embodiment; Figure 24 This is a structural block diagram of a computer device provided in an embodiment of this application. Detailed Implementation

[0019] In the following description, only certain exemplary embodiments are briefly described. As those skilled in the art will recognize, the described embodiments can be modified in various ways without departing from the spirit or scope of this application. Therefore, the drawings and description are considered to be exemplary in nature and not restrictive.

[0020] Among related technologies, neonatal brain MRI segmentation technology can support subsequent analyses (such as brain volume measurement, cortical maturity tracking, and individualized connectome construction). Compared with adult MRI, early life scans show rapid changes in anatomical and tissue microstructures during postmenstrual age (PMA), manifested as lower or even inverted T1w / T2w contrast, significant local volume effects, and motion artifacts. These factors make neonatal MRI one of the most challenging research areas for automated segmentation, specifically manifested in the following ways: (1) Rapid development process causes non-steady changes in the shape and appearance of the newborn's brain tissue within a few weeks; (2) Low contrast blurs the tissue boundaries of the developing brain; (3) Differences between different scanners, institutions and testing methods reduce the universality of test results; (4) In practical applications, neonatal MRI itself has three-dimensional volume characteristics, which means that neonatal brain MRI segmentation technology must maintain the consistency of cross sections while maintaining computational tractability.

[0021] While modern medical segmentation frameworks (such as U-Net, 3DU-Net, V-Net, nnU-Net, and UNETR) are powerful general-purpose benchmark models, they typically rely on fully supervised training and large amounts of labeled data, and often require expensive retraining or fine-tuning to transfer between different datasets. This challenge is particularly pronounced in the field of neonatal brain MRI analysis, where expert annotation is costly and the differences between evaluators are significant. Furthermore, the current field of neonatal and infant image segmentation has long relied on atlas label propagation and probability strength models (such as the Draw-EM framework and dHCP structure processing workflow), which, while providing strong prior information, require careful design and may be vulnerable to changes in the approach.

[0022] Open infant databases such as the Open Infant Brains (BOBs), with their expert-reviewed multi-tissue segmentation data, highlight the urgent need to develop universal models that can span early life stages. Furthermore, the BONBID-HIE dataset includes MRI scans labeled by experts as hypoxic-ischemic encephalopathy (HIE) lesions. These lesions are diffusely distributed and occupy less than 1% of the brain volume, constituting a unique and challenging research topic in neonatal brain MRI segmentation. These benchmark datasets collectively underscore the practical need for efficient annotation adaptation across modalities, sites, and developmental stages.

[0023] Meanwhile, the field of computer vision has shifted from training task-specific architectures to adapting large pre-trained (“base”) models through cues and efficient parameter tuning. Cue-enabled segmentation models such as SAM, along with general-purpose decoders like Mask2Former, offer a compelling interface: freezing strong backbones and adapting to new domains through lightweight modules. These large-scale pre-training strategies are based on representation learning paradigms at the ImageNet scale, which have profoundly impacted transfer learning in medical imaging. Parameter-efficient tuning protocols such as Visual Cue Tuning (VPT) and LoRA reduce adaptation costs by updating only a small subset of parameters. In medical imaging, MedSAM, SAM-Med2D, and adapter-based methods (such as the Medical SAM Adapter (Med-SA)) have demonstrated the feasibility of adapting cue-enabled backbones to the medical field.

[0024] However, neonatal MRI introduces an additional nonstationar dimension (developmental stage) and an application environment where test time robustness is crucial, which necessitates explicit age conditionation and inference time optimization without parameter tuning.

[0025] Based on this, this application proposes a two-dimensional slice-based multi-class segmentation framework model (i.e., the NeoPromptFormer segmentation model). This model applies a cue-enabled basic visual backbone network to the field of neonatal brain MRI segmentation through efficient parameter learning and developmental condition adjustment. Specifically, the NeoPromptFormer segmentation model combines the effects of efficient parameters, age-conditional cues, and test time optimization on neonatal brain MRI segmentation, and mainly includes the following core components: (i) PEFT-MAE module: Designed specifically for neonatal brain MRI, it employs a parametrically efficient masked autoencoder prefitting strategy. Based on the instantiated age cues output by the Age-Prompt module, it performs parametrically efficient fine-tuning of the encoding process for the input image. For example, based on the parametrically efficient masked autoencoder prefitting strategy, it uses masked autoencoders that only update the low-rank adaptation (LORA) adapter and age cues, bridging the apparent differences between natural and medical images without comprehensive fine-tuning. (ii) Age-Prompt module: Based on the input image, PMA dynamically generates instantiated age prompt words from a learnable age condition prompt library, and transmits the instantiated age prompt words to the PEFT-MAE module for encoding adjustment; (iii) TQ-Decoder module: Based on the output features of the PEFT-MAE module, it generates the initial segmentation prediction result of the input image, and performs test optimization on the initial segmentation prediction result without parameter tuning based on the prompt words or query variables of the input image under the condition of differentiable dissection prior, and outputs the optimized final segmentation prediction result.

[0026] The NeoPromptFormer segmentation model provided in this application can utilize the prior knowledge of the base model, efficiently adapt to neonatal brain MRI under limited supervised label conditions, and maintain robustness to changes at different developmental stages and different segmentation tasks.

[0027] To facilitate those skilled in the art to understand the relevant technical solutions provided in the embodiments of this application, the relevant terms involved in this application will be explained below.

[0028] Postmenstrual age (PMA) refers to the total number of weeks from the first day of the mother's last menstrual period to the present time. It is calculated as gestational age (ga) + age after birth and is an important indicator for assessing the development of premature infants or newborns.

[0029] T1w / T2w contrast: In MRI, this refers to the imaging parameter that reflects tissue characteristics by comparing the difference in signal intensity between the same tissue on T1-weighted (T1w) and T2-weighted (T2w) images.

[0030] The relevant technical solutions provided in the embodiments of this application will be described in detail below with reference to the accompanying drawings.

[0031] Figure 1 A flowchart illustrating a method for segmenting neonatal brain MRI images according to an embodiment of this application is shown. Figure 1 As shown, the method may include the following steps: S110. Obtain the sample dataset.

[0032] In one implementation, the sample dataset may include multiple neonatal brain MRI images. Each neonatal brain MRI image may contain its corresponding label map, which includes the neonatal PMA (Physical Mental Anatomy). Alternatively, the label map can be understood as three-dimensional spatial annotation metadata containing category labels, which include the neonatal PMA.

[0033] In practical applications, each neonatal brain MRI image is essentially volumetric data (i.e., three-dimensional data). Based on this, in the embodiments of this application, the three-dimensional volume of each neonatal brain MRI image and its corresponding label mapping are expressed by the following formulas (1) and (2), respectively.

[0034] (1) In formula (1), V represents the three-dimensional volume of each neonatal brain MRI image; H, W, and D1 represent the height, width, and depth of each neonatal brain MRI image, respectively; C1=1 corresponds to T2w, and C1=2 corresponds to stacked T1w / T2w.

[0035] (2) In formula (2), Y represents the label mapping map corresponding to each neonatal brain MRI image; K represents the total number of all segmentation categories in the label mapping map, and the label values ​​are encoded from 0 to K. 1.

[0036] As an example, each neonatal brain MRI image in this sample dataset can be selected from the BOBs dataset and the BONBID-HIE dataset.

[0037] S120. Perform two-dimensional slicing on each neonatal brain MRI image in the sample dataset to obtain the processed sample dataset.

[0038] In one implementation, the process of step S120 may include the following sub-steps: S121. Perform two-dimensional slicing on each neonatal brain MRI image in the sample dataset to obtain multiple slices corresponding to each neonatal brain MRI image.

[0039] As an example, the following formula (3) can be used to divide each neonatal brain MRI image in the sample dataset into multiple slices along the axis.

[0040] (3) In formula (3), This is represented as the d1st slice of each newborn's brain MRI image; , D1 represents the volume data and annotation data of the d1th slice, respectively; D2 represents the total number of slices corresponding to each neonatal brain MRI image.

[0041] S122. Stack adjacent slices from multiple slices to obtain each newborn brain MRI image after two-dimensional slicing.

[0042] As an example, during the inference process, the slice prediction results can be stacked to obtain a three-dimensional segmentation and a volumetric index can be calculated. For example, in order to partially recover the cross-slice context, a two-dimensional input can be formed by stacking adjacent slices according to the following formula (4), followed by a 1×1 channel mixing layer to match the input dimension of the backbone network, so as to obtain each neonatal brain MRI image after two-dimensional slice processing.

[0043] (4) S123. Based on each neonatal brain MRI image after two-dimensional slicing, a processed sample dataset is obtained.

[0044] This can be understood as the processed sample dataset including multiple neonatal brain MRI images after two-dimensional slicing.

[0045] In this embodiment of the application, by executing step S120, each neonatal brain MRI image in the processed sample dataset after two-dimensional slicing can be matched with the input dimension of the NeoPromptFormer segmentation model.

[0046] S130. Based on a promptable basic visual backbone network, construct the NeoPromptFormer segmentation model.

[0047] In one implementation, combined with Figure 1 and Figure 2 As shown, the NeoPromptFormer segmentation model is a two-dimensional slice-based multi-class segmentation framework model, which includes the PEFT-MAE module, the Age-Prompt module, and the TQ-Decoder module.

[0048] In one implementation, the segmentation prediction process of the NeoPromptFormer segmentation model can be as follows: S131. Using the PEFT-MAE module, a parameter-efficient mask autoencoder pre-adaptation strategy is employed. Based on the instantiated age prompt words output by the Age-Prompt module, the encoding process of the input image is finely tuned.

[0049] As an example, the PEFT-MAE module may include a lightweight modal adapter, a LoRA adapter, and a pre-trained ViT image encoder and MAE decoder from the SAM model. In this case, the implementation of step S131 may include the following sub-steps: S1311. Use a lightweight modal adapter to map the input image to the basic visual backbone network of the ViT image encoder.

[0050] For example, the NeoPromptFormer segmentation model provided in this application starts with the ViT image encoder, which is part of the pre-training of the SAM model. Since neonatal brain MRI is grayscale / multi-contrast rather than RGB, this application uses a lightweight modal adapter to map the input image to the basic visual backbone network (Transformer module) of the ViT image encoder. The lightweight modal adapter can be a learnable 1×1 convolutional layer.

[0051] For example, a lightweight modal adapter can be used to map the input image to the underlying visual backbone network of the ViT image encoder based on the following formula (5).

[0052] (5) In formula (5), This represents a lightweight modal adapter; x represents a slice of the input image. denoted as x, the image feature after adaptation; C2 represents the number of channels, such as 3; E represents the ViT image encoder; z represents the output feature of the ViT image encoder; d2 represents the feature dimension of the output feature; N represents the number of image patches.

[0053] S1312. Use the ViT image encoder to perform feature encoding on the input image based on the instantiated age prompt words output by the Age-Prompt module.

[0054] In specific implementation, step S1312 can use the existing processing logic of the ViT image encoder (which will not be described again in the embodiments of this application), while introducing developmental age conditionalization.

[0055] As an example, a P-learned cue word (i.e., an instantiated age cue word) can be added before the embedded layer cue sequence at the input of the Transformer module selected by the ViT image encoder. This design follows the principle of efficient parameter cue tuning and also supports age condition cueing in the embodiments of this application. This process can be represented by the following formula (6).

[0056] (6) In formula (6), This is represented as an instantiated age-sensitive word; This is represented as PMA metadata (i.e., PMA data annotated in the input image). It represents the index converter module; patch represents the image patch.

[0057] S1313. Adaptively adjust each attention projection matrix in the selected base visual backbone network of the ViT image encoder using the LoRA adapter.

[0058] For example, each attention projection matrix in the selected base visual backbone network (Transformer module) of the ViT image encoder can be represented as: In this case, the adaptive adjustment process of the LoRA adapter for each attention projection matrix W can be expressed by the following formula (6).

[0059] (7) In formula (7), only A and B are trainable, and W is frozen. Here, A represents the projection matrix from the original feature space to the low-dimensional subspace (dimensionality reduction mapping); B represents the reconstruction matrix from the low-dimensional subspace back to the original feature space (dimensionality increase mapping); r represents the rank of the low-rank decomposition, which is much smaller than the original feature dimension d2. It is used to characterize the dimension of the low-dimensional subspace and significantly reduce the size of trainable parameters while ensuring the expressive power of the model.

[0060] S1314. Using the MAE decoder, a parameter-efficient mask self-encoding pre-adaptation strategy is employed to perform parameter fine-tuning of the encoding process of ViT image encoding.

[0061] As an example, prior to supervised training, the MAE decoder can be tailored to the appearance of a newborn's brain MRI using a masked autoencoder approach, updating only the lightweight modality adapter. Instantiated age-sensitive words (e.g.) ) and parameters of the LoRA adapter.

[0062] For example, for each slice x in the input image, a portion of the image patch in each slice x is randomly masked using the MAE decoder. For instance, a masking ratio could be used. For each slice x, a set of Ω block indices are randomly masked; then, the masked image blocks in each slice are reconstructed using a lightweight decoder R with a MAE decoder. During this process, the lightweight modality adapter is updated only by minimizing the loss between the reconstructed image blocks and the original image blocks in each slice. The parameters of the ViT image encoding, the instantiated age prompts, and the parameters of the LoRA adapter are used. After pre-adaptation, only the parameter-efficient fine-tuning (PEFT) parameters adapted during the encoding process of ViT image encoding are retained. That is, after pre-adaptation, the lightweight decoder R will be discarded. This process can be represented by the following formula (8).

[0063] (8) In formula (14), This is represented as the image reconstructed by the lightweight decoder R; A set of image patch indices represented as a random mask, containing the masked image regions; This is represented by the number of image patch indices that are masked. Represented as the first i A masked image block index; Represented as a decoder function; Represented as a reconstruction loss function based on a mask autoencoder mechanism, it is used to constrain the difference between the reconstruction result and the original image. This loss function is only calculated on the masked region, which helps to improve the model's ability to represent local structures and achieve efficient pre-adaptation of parameters.

[0064] S132. Using the Age-Prompt module, based on the PMA of the input image, an instantiated age prompt word is dynamically generated from a learnable age condition prompt library, and the instantiated age prompt word is transmitted to the PEFT-MAE module for encoding adjustment.

[0065] In practical applications, the physical characteristics of newborns will vary significantly with PMA. Based on this, the embodiments of this application simulate this non-stationarity by generating prompts from an age-conditionalized database.

[0066] For example, we can pre-define M basic age cue word sets corresponding to each basic visual backbone network of the PEFT-MAE module. This can also be understood as the M basic age cue word sets representing each index converter module. The basic age cue word set, wherein the M basic age cue word sets can be represented as Subsequently, the Age-Prompt module can be used to map the PMA (in weeks) of the input image into an M-dimensional hybrid weight vector through a multilayer perceptron (MLP). Then, the M basic age prompt word sets are weighted and summed according to the hybrid weight vector to obtain the instantiated age prompt words. For example, this process can be represented by the following formula (9).

[0067] (9) In formula (9), This is represented as the PMA corresponding to the input sample; Let be a mixed weight vector generated by 'a', and satisfy ... This is used to weight and combine multiple basic prompt words; Represented as MLP, it is used to store age information (such as...) The weights are mapped to a weight vector; Softmax represents the normalization function used to map the weights to a probability distribution. This is represented as the weight coefficient corresponding to the m-th basic prompt word; Represented as the first The m-th basic cue word vector in the layer; This refers to the instantiated prompt word generated under age condition a; This represents the network layer index.

[0068] In the above process, in order to achieve smoothness of the age span, the Age-Prompt module can be used to apply smoothness regularization constraints to adjacent age prompts in the instantiated age prompts, so as to avoid discontinuous age prompt switching and encourage developmental continuity. The smoothness regularization constraint can be expressed by the following formula (10).

[0069] (10) In formula (10), Represented as a smaller age perturbation (e.g., 1 week); E a This is represented as a smoothness regularization constraint.

[0070] Finally, the Age-Prompt module can be used to transmit the instantiated age prompt words to the PEFT-MAE module for encoding adjustments.

[0071] S133. Utilize the TQ-Decoder module to generate the initial segmentation prediction result of the input image based on the output features of the PEFT-MAE module, and perform test optimization of the initial segmentation prediction result without parameter tuning based on the prompt words or query variables of the input image under the condition of differentiable dissection prior, and output the optimized final segmentation prediction result.

[0072] As an example, the implementation of step S133 may include the following sub-steps: S1331. Using the TQ-Decoder module, K learnable category queries are used. Through a Transformer decoder, cross-attention decoding is performed with instantiated age prompts to generate K refined category queries.

[0073] As an example, when the query volume of K learnable categories When expressed, the implementation process of sub-step S1331 can be represented by the following formula (11).

[0074] (11) In formula (11), It is represented by K refined category query volumes; Decoder is represented by Transformer decoder.

[0075] S1332. Using the TQ-Decoder module, generate the initial segmentation prediction results of the input image based on K refined category queries.

[0076] As an example, pixel-level features can be used. The initial segmentation prediction result of the input image is generated by the dot product operation between the (obtained by reconstructing encoder features and upsampling) and K refined category queries. This process can be represented by the following formula (12).

[0077] (12) In formula (12), (i,j) represents the pixel coordinates in the input image; f ij Represented as the (th) i , j The pixel feature vector at position q; k Represented as the query vector of the k-th class; It is represented as the matching score of a pixel belonging to the k-th class; This is represented as the predicted probability distribution of pixels across each category; It is represented as a normalization function along the category dimension; k represents the category index, 1≦k≦K; This represents the initial segmentation prediction result for the input image.

[0078] S1333. In the model inference stage, the TQ-Decoder module is used to update the category query offset with small residuals, and the weight of the instantiated age prompt is fixed to the output of the PEFT-MAE module. Then, the target supervision function is used to supervise the initial segmentation prediction results and output the optimized final segmentation prediction results.

[0079] In practice, this category query offset is the difference between each learnable category query and its corresponding refined category query.

[0080] As an example, for the first unlabeled target slice in the input image, the TQ-Decoder module can be used to initialize the class query offset corresponding to the first target slice, and a T-step gradient descent can be performed on the composite energy. This optimization does not require tuning of the network weights; the model weights remain frozen. Only the class query offset of each first target slice is tuned. Optimization is performed using the optimized hyperparameters fixed in the experiment as the output of the PEFT-MAE module. This implementation process can be represented by the following formula (13).

[0081] (13) In formula (13), This represents the parameter increment in the t-th iteration; This is expressed as the step size (also known as the learning rate); This is represented as a modulation function based on auxiliary information a (such as age cues); The loss function can be defined using the following formula (14), where p represents the model's predicted output. This is represented as entropy loss. Represented as edge constraint loss, This is represented as attention-constrained loss. , , They are respectively represented as , , The loss weight.

[0082] (14) Formula (14) must satisfy the following conditions: 1) Minimization encourages the model to output more definitive predictions, thereby improving the confidence of the segmentation predictions. (15); In formula (15), Used to measure the uncertainty of the model output; This is represented as the predicted probability value of belonging to the k-th class at pixel position (i,j); k represents the class index. This is represented as a summation operation over all pixel positions; This is represented as the summation of all categories; log is represented as the natural logarithm function. This is expressed as an average of all pixels; Formula (15) can be used as a self-supervised constraint in the unsupervised testing phase, which helps to improve the robustness of the model under distribution shift conditions; 2) Edge alignment aligns the mask boundaries with image gradients, enhancing the boundary accuracy of segmentation predictions and making the model's predictions more consistent with the true structural information of the image. By introducing image gradient priors, it helps improve the model's boundary recognition ability in low-contrast medical images. (16) In Equation (16), G(x) is a simple edge detector (e.g., Sobel magnitude). This represents the edge gradient information of the input image; stopgrad indicates a gradient stopping operation, used to prevent the gradient from propagating backward from this branch, thereby avoiding degradation. This is represented as the edge alignment loss function, used to constrain the boundaries of the segmentation result to be consistent with the true edges of the image; Represented as the spatial gradient operator; This represents the boundary gradient information of the segmentation prediction result; Represented as this The category response with the highest predicted probability at each pixel; The L1 norm is represented by , which is used to measure the difference between the two. Formula (16) helps to improve the model's ability to identify boundaries in low-contrast medical images by introducing image gradient priors. 3) Attention / regional priors enforce reasonable foreground coverage (roughly defined brain mask area) through soft constraints, thereby penalizing regression: (17) In formula (17), It is represented as a constraint loss function based on region priors, used to limit the proportion of the foreground region in the prediction results; Represented as this The category index with the highest predicted probability at each pixel; It is represented as an exponential function, taking a value of 1 when the condition is true, and 0 otherwise; Represented as this Pixels are classified as foreground regions; category 0 indicates the background category. Represented as the expected foreground region proportion obtained statistically from the training data; squared term This is used to constrain the difference between the predicted foreground ratio and the prior ratio, thereby avoiding degradation of the entire foreground or background. Formula (17) helps to stabilize model prediction and improve robustness in small lesion segmentation tasks by introducing a global region prior.

[0083] In the example above, a target supervision function can be used to supervise the initial segmentation prediction results and output the optimized final segmentation prediction results.

[0084] For example, for a second target slice with labels in the input image, the TQ-Decoder module can be used to optimize the combination of the standard segmentation loss function and age smoothness using the following formulas (18) and (19): (18) (19) In formulas (18) and (19), Represented as a supervised loss function; Represented as Dice loss; Represented as boundary loss; , , They are respectively represented as , , Loss weights; Represented as the total loss function; This is represented as age-smoothing loss; This is represented by the age-smoothing loss weight.

[0085] In this embodiment of the application, by executing step S130, the constructed NeoPromptFormer segmentation model can combine the effects of parameter efficiency, age condition cues, and test time optimization on neonatal brain MRI segmentation. It can utilize the prior knowledge of the basic model, efficiently adapt to neonatal brain MRI under limited supervised label conditions, and maintain robustness in different developmental stages and different segmentation tasks.

[0086] S140. Using the processed sample dataset, the NeoPromptFormer segmentation model is trained to obtain the NeoPromptFormer segmentation model.

[0087] In practical implementation, relevant training methods can be adopted according to actual needs. The NeoPromptFormer segmentation model can be trained using the processed sample dataset. The embodiments of this application will not be described in detail here. For example, the training can be performed using the implementation method described in the following experimental process.

[0088] S150. Obtain MRI images of the newborn's brain.

[0089] In one embodiment, the MRI image of the newborn's brain to be tested can be obtained in real time from the medical management system of the relevant hospital, or it can be obtained by other means. This application embodiment does not specifically limit this.

[0090] S160. Perform two-dimensional slicing on the MRI image of the newborn's brain to be tested, and obtain the MRI image of the newborn's brain after two-dimensional slicing.

[0091] In one embodiment, the implementation process of step S160 may be the same as or similar to the implementation process of step S120 described above, and will not be repeated here in the embodiments of this application.

[0092] S170. Input the neonatal brain MRI image after two-dimensional slicing into the NeoPromptFormer segmentation model for segmentation processing to obtain the final segmentation prediction result of the neonatal brain MRI image to be tested.

[0093] To further facilitate understanding of the neonatal brain MRI image segmentation method provided in this application, the following is combined with... Figures 3-22 Verification was conducted through relevant experiments.

[0094] I. Experiment 1.1 Dataset The BOBs dataset contains 71 sessions from 51 participants (aged 1-9 months), along with expert-reviewed segmentation results for nine tissue types and T1w / T2w images. The nine tissue segmentation results are categorized into two types: background and abnormal / other. In the experiment, these two categories (abnormal / other) were excluded when reporting mDice to focus on anatomical tissues. The BOBs dataset was used for multi-tissue brain segmentation assessment in the experiment. A session refers to a recording unit at different time points during neonatal brain scan data acquisition.

[0095] The BONBID-HIE dataset reported 133 newborns in its original version. In this local snapshot, 85 subjects had complete paired ADCs and lesion labels for training / evaluation. HIE lesions are characterized by their diffuseness and small size—more than half of the patients had lesions occupying less than 1% of the brain volume, making binary segmentation tasks challenging.

[0096] 1.2 Preprocessing and Two-Dimensional Slicing 1.2.1 Reorient to a common orientation (e.g., RAS), resample to a fixed in-plane resolution (e.g., 256×256), and crop out a tight brain bounding box.

[0097] 1.2.2 Intensity standardization for each subject (z-score within the brain region mask). For BOBs, rigid registration and channel stacking are performed if T1w and T2w images are available; for BONBID-HIE, the ADC map is used as a single-channel input.

[0098] 1.2.3. Slice extraction: Axial slices containing non-trivial brain regions; optional 2.5D stacking (Formula (4) above).

[0099] 1.3 Implementation Details Model architecture: SAM-ViT-B is used as the backbone encoder. LoRA uses rank r=8. A dropout rate of 16 and 0.1 was applied to all 12 Transformer modules. Age cues (P=8) were inserted at layers {0, 3, 6, 9}. The AgePrompt module used M=5 basic age cue sets, employing a 64-dimensional MLP and =1 week of smoothness. When LLM initialization cues are integrated into the base cue vector via soft fusion (fusion coefficient) =0.05 (see Table 6), then LLM is used to initialize the hint. Here, "LLM-init" refers to the offline hint-embedding vector generated by Qwen3-4B, which is only used to warm up the hint parameters (no LLM inference is required during training or deployment). The TQ-Decoder module has a 3-layer structure with 8 heads per layer and a query dimension of 256.

[0100] Training Procedure: Unless otherwise specified, all models were trained using AdamW (learning rate = 1e-4, weight decay = 0.01) for 50 epochs with a batch size of 8, and a cosine scheduler with 5-epoch warm-up. Data augmentation methods included random horizontal / vertical flipping, 90-degree rotation, intensity scaling (0.9–1.1), and Gaussian noise. For PEFT-MAE module prefitting, mask ratio was used in this experiment. =0.75 and lr=1e-3, the number of prefitting rounds follows the ablation settings. For BONBID-HIE, the main comparisons in Table 2 use a uniform 2D protocol (Δ=0), while dedicated context ablation uses a 2.5D setting (Δ=1,2).

[0101] Adaptive during testing: TTA performs T=10 gradient steps on each test slice, with a step size of =0.01. Energy weight is =0.1、 =0.1 and =0.05.

[0102] Reproducibility: Subject grouping (70 / 15 / 15) was generated using a fixed segmentation function based on subject ID in this study, with a fixed randomization factor. Reports are presented as mean ± standard deviation and 95% confidence intervals. When available, the median (IQR) and lesion diagnosis results for BONBID-HIE are detailed in Section 1.7 below. In the current data snapshot of this study, BOBs_real contains 51 available subjects (training / validation / test set ratio of 35 / 7 / 9; number of slices 3324 / 649 / 837), while BONBID-HIE contains 85 available subjects with paired ADC+ labels (training / validation / test set ratio of 59 / 12 / 14; number of slices 1817 / 308 / 446).

[0103] 1.4 Baseline In this experiment, the NeoPromptFormer segmentation model is compared with representative medical adaptation methods based on adaptive models (SAM), efficient general parameter tuning strategies, and traditional fully supervised segmentation baseline methods. The method names used below (including tables and figure captions) remain consistent.

[0104] MedSAM: A SAM-style prompting segmentation model trained on large-scale medical domains to adapt to medical images.

[0105] SAM-Med2D: A comprehensive SAM-based medical solution for two-dimensional medical segmentation.

[0106] Medical SAM Adapter: An adapter-based strategy that bridges intermodal differences by learning lightweight adaptation modules rather than retraining the entire backbone network.

[0107] LoRA: An efficient adaptive method for updating model parameters by modifying low-rank weights.

[0108] Visual Cue Tuning (VPT): A parameter-efficient adaptive strategy that guides a frozen backbone network by learning a small number of cue tags.

[0109] U-Net: A standard encoder-decoder baseline model trained end-to-end on a target dataset.

[0110] nnU-Net: A pipeline based on self-configured U-Net as a powerful universal medical segmentation baseline.

[0111] TransUNet: A Transformer-enhanced U-Net baseline model for medical image segmentation. All baseline models employ the same preprocessing, data segmentation, and training scheme as the NeoPromptFormer segmentation model to ensure fair comparison.

[0112] 1.5 Evaluation Indicators For BOBs multi-tissue segmentation, this study reports the individual mean Dice value (mDice) and its 95% confidence interval, and reports the minimum Dice value across categories (minDice) to assess robustness. Background and outliers / other categories were excluded when calculating mDice.

[0113] Regarding BONBID-HIE lesion segmentation, this trial reports the Dice value (binary classification) for lesions segmented by subject, PR-AUC, and sensitivity (Sens@Spec97) at the 97% specificity operating point. PR-AUC and Sens@Spec97 are of particularly important informational value due to the small lesion size and class imbalance. Median (IQR) and lesion-level diagnostic metrics (lesion recall and false positive rate per scan) are detailed in Section 1.7 (if applicable).

[0114] Threshold setting and aggregation details (BONBID-HIE): PR-AUC is calculated by stitching together all subject score maps at the voxel level. Sens@Spec97, on the other hand, scans the same stitched score maps and selects the highest sensitivity value among the computational points with specificity ≥0.97 for calculation. To ensure reproducibility, this experiment reports the corresponding threshold (thr_at_spec_0p97), which is a summary statistic of computational points, rather than a fixed deployment threshold for each subject.

[0115] 1.6 Main Results 1.6.1 BOBs Multi-Tissue Segmentation Table 1 compares the performance of traditional fully supervised baseline models (U-Net, nnUNet, and TransUNet) with SAM-based adaptive methods in multi-tissue segmentation of BOBs. NeoPromptFormer+LLM achieves the best mDice score (0.8504) and the highest minDice value (0.6946), indicating excellent performance across different tissue categories. Specifically, the NeoPromptFormer segmentation model provided in this application surpasses traditional baselines (UNet: 0.5543, nnUNet: 0.5775, TransUNet: 0.6534) as well as Medical SAMAdapter (0.7451) and SAM-Med2D (0.7678) in mDice while maintaining efficient parameter tuning. The gap with VPT and LoRA baselines highlights the value of combining multiple PEFT strategies with developmental conditions for training.

[0116] 1.6.2. BONBID-HIE lesion segmentation Table 2 compares the performance of traditional fully supervised baseline methods (U-Net, nnUNet, and TransUNet) with SAM-based methods on BONBID-HIE lesion segmentation, using the optimal validation checkpoints for each method and employing a uniform 2D input protocol (the same fixed 14 subjects for segmentation testing and subject-level metrics). This protocol follows Table 3, where the 2D protocol yielded the highest lesion Dice values ​​in the final NeoPromptFormer setting; 3-layer / 5-layer variants were retained as diagnostic negative controls and not used in the final protocol. The task remains challenging (median lesion volume: 0.03% of brain tissue), therefore the subject-level Dice values ​​for each method remain highly varianced. Under this unified protocol, NeoPromptFormer+LLM achieved optimal lesion Dice / PR-AUC / Sens@Spec97 (0.2354 / 0.7643 / 0.9823), outperforming traditional baseline methods in lesion Dice (U-Net: 0.1837, nnU-Net: 0.1883, TransUNet: 0.2003). Compared to the strongest SAM baseline method (Medical SAM Adapter), the Dice gain was +0.0101, and the PR-AUC gain was +0.0428; the paired Wilcoxon test in Table 9 shows that the Dice gain was significant relative to Medical SAMAdapter, LoRA, SAM-Med2D, VPT, and MedSAM (all p < 0.05).

[0117] 1.7 Ablation Research 1.7.1 General Protocol (Uniformly applied in ablation procedures) Segmentation: All reports are segmented by subject / session (never by slice), and #subject and #session are clearly labeled in the training / validation / test sets.

[0118] Factors: The critical sensitivity settings should be run with at least 3 randomized factors and report the mean ± standard deviation among the factors.

[0119] Statistics: The main comparisons reported paired tests (Wilcoxon signed-rank test) for 95% confidence intervals and individual subject indicators, along with incidental effect sizes.

[0120] Statistical reporting standards: For each primary comparison, this study reports n, the mean difference between subjects, the two-sided Wilcoxon p-value, the rank sum correlation coefficient, and the paired Cohen's d. The normality of paired differences (Shapiro-Wilk test) and the results of paired t-tests are used as sensitivity tests.

[0121] Metric Aggregation: • BOBs_real main table (Table 1): Calculate the number of dice for each subject in each category → mDice by subject category after excluding background and outliers / others ({0,4}).

[0122] • BOBs Core Tips / Age Scan (Tables 4 and 5): Report the mDice definitions used for these checkpoints (clearly stated in each heading) and avoid direct absolute comparisons with Table 1.

[0123] • BONBID-HIE: Reports Dice value, PR-AUC value, and lesion-level parameters (lesion recall and number of false positive lesions per scan image). Also reports sensitivity at fixed specificity.

[0124] Training protocol: Ablation experiments use the same protocol as the final model (training epochs, data augmentation, optimizer, learning rate scheduling). When fast ablation is included, it will be clearly marked as preliminary results and excluded from the main conclusions.

[0125] Protocol Alignment Notes: For the BONBID-HIE modules / loss ablation in Tables 4, 5, 7, and 8, the checkpoints were reassessed using the same subject-specific protocol (fixed 14-subject test segment) as in Table 2. Tables 4, 5, 7, and 8 are single-factor (seed42) diagnostic scans, and their results are interpreted as trend-level evidence rather than final significance statements.

[0126] 1.8, Level 1: Module ablation completed 1.8.1、 (I) Context depth sensitivity (Formula (4) above) Table 3 presents the final subject-specific 2D / 2.5D sensitivity comparison results on BONBID-HIE (3 factors). In this setting, adjacent slices are added ( While methods 1 and 2 can improve PR-AUC, they decrease the primary endpoint (lesion Dice value) and have no effect on the Sens@Spec97 index. This pattern is consistent with the contextual side effects in small lesion detection (increased ranking stability but reduced operation point overlap). Therefore, this experiment fixed the primary BONBID protocol as follows: =0, and will =1,2 serve as negative diagnostic controls under the current lesion loss / sampling protocol.

[0127] 1.8.2, (II) Lightweight Modal Adapter and (III) LoRA Adapter The final model retains the lightweight modal adapter in Equation (5) above and the LoRA rank r=8 in Equation (6) above. The parameter efficiency is summarized in Table 10.

[0128] 1.8.3、 (IV) Prompt Marking (Formula (7) above) Table 4 reports the formal cue length ablations (P∈{1,4,8,16,32}) using a uniform subject BONBID-HIE assessment at the matched seed42 checkpoints. Here, “BOBs_core” refers to the core ablation cohort bound to these checkpoints (different from the reporting flow of the main BOBs_real table). BOBs peaked at P=8. In the BONBID-HIE assessment, P=4 yielded the highest subject lesion Dice value (0.2385), while P=1 yielded the highest PR-AUC value (0.6889), indicating a slight cue length trade-off between operational criteria. Overall, this single-factor diagnosis did not show a monotonic advantage from increased cue length. A stable range is formed, while P≥16 tends to decrease the ranking / operation point index.

[0129] 1.8.4、 (V) AgePrompt large-volume ablation (Formulas (9) and (10) above) Table 5 presents the large-volume ablation experiments of the core AgePrompt module, using a uniform subject BONBID-HIE index. For BOBs, M=5 remains optimal; for bonbidhie, M=5 yields the highest lesion Dice / Sens@Spec97, while M=3 yields the highest PR-AUC, indicating that the operating range of M=3–5 is stable. This diagnostic scan suggests the existence of an optimal value within a moderate range rather than "the larger the better"; M=3–5 is a robust choice across tasks / indicators.

[0130] 1.8.5、(VI) PEFT-MAE timetable (Formula (8) above) Table 6 presents the topic-by-topic foundation-to-full path analysis of three factor samples based on the BOBs_real dataset under a stable continuation setting. This is in contrast to the base model, age-hint model, and LLM soft-initialization model (LLM-init; Qwen3-4B vector preheating start, hybrid model). Compared with the PEFT-MAE model (=0.05), both showed positive mean differences, and the paired statistics of the three factor samples have been summarized.

[0131] 1.8.6、(VII) TQ-Decoder diagnosis (Formula (11) and Formula (12) above) Evidence for TQ-Decoder is presented in Figure 2 , Figure 3 and Figure 4The data includes category query response graphs, confusion matrices, and category Dice values. These diagnostic results are generated based on retained real data and use the same checkpoints as the main comparison.

[0132] 1.8.7, (VIII) Test time refinement item without tuning Table 7 shows the comparison of BONBID-HIE TTA energy term diagnostic results across 42 factor checkpoints under fixed subject segmentation conditions. To highlight the term-level effect, Table 7 only uses mask-based diagnostic indicators (lesion Dice value and voxel-level false positive / false negative rate of refined mask), omitting score-based indicators (PRAUC, Sens@Spec97). Key findings: In the scenario of small lesions, the entropy + edge method can obtain the optimal Dice value with a controllable false positive rate, while introducing the area term may increase the false positive rate and cause Dice value instability.

[0133] 1.8.8, (IX) BONBID loss × sampling ablation Table 8 summarizes the interaction between BONBID-HIE loss and sampling under the same subject protocol as Table 2. In the scenario of small lesions, the Dice index alone was unstable (0.0295–0.0714), while the Dice+Focal combination index group showed the most stable performance. When using Dice+Focal for lesion oversampling, the lesion Dice value was the highest (0.2312); while the uniform sampling Dice+Focal combination obtained the strongest PR-AUC / Sens@Spec97 index (0.7571 / 0.9532). The Focal-Tversky index was competitive with uniform sampling (0.2212), but its performance decreased after oversampling (0.2114). Overall, the Dice+Focal combination is the best choice; oversampling mainly improves the PR-AUC, while uniform sampling better maintains PR-AUC and high specificity and sensitivity.

[0134] 1.9 Other Visual Evidence Figure 13 , Figure 14 and Figure 15 The results of TQ-Decoder analysis based on real retained data are presented, including category query response graphs, test set confusion matrices, and comparisons of Dice values ​​for each category. Figure 16 Runtime and parameter efficiency analysis is presented.

[0135] Specifically, Figure 13 The TQ-Decode module is based on the category query response probability map of the real subjects, with the GT outline marked inside. Figure 14This is the TQ-Decode module's up-normalized confusion matrix on the full BOBs_real test set (MedSAM vs NeoPromptFormer). Figure 15 These are the Dice values ​​for each category, calculated based on the same obfuscation count, corresponding to the TQ-Decode module diagnostics. Figure 16 In the text, (a) shows the runtime-memory tradeoff (milliseconds / slice vs. peak GPU memory); (b) shows the relationship between the percentage of trainable parameters and mDice in different methods.

[0136] 1.10 Statistical Analysis All significance tests employed a two-tailed paired Wilcoxon signed-rank test to calculate individual participant indicators, with paired Cohen's d and rank-based biserial correlation coefficients reported as effect sizes. In ablation comparisons, paired checkpoints were factor-matched (e.g., seed777 vs seed777) to avoid confounding effects.

[0137] On BOBs (n=9 subjects), the NeoPromptFormer segmentation model improved by an average of +0.0078 mDice compared to the fixed cue baseline checkpoint (Wilcoxon p=0.0039, rank-sum test=1.00, paired Cohen's d=1.62). Under the same subject protocol, NeoPromptFormer+LLM achieved 0.8504 mDice, while the Medical SAM Adapter achieved 0.7451 (Table 1).

[0138] In BONBID-HIE (n=14 subjects; uniform two-dimensional protocol), the NeoPromptFormer segmentation model improved the lesion Dice value by an average of 0.0101 compared to the Medical SAM Adapter, and this strongest baseline comparison was statistically significant (p=0.0196). NeoPromptFormer also showed significant improvements in the Dice metric compared to several SAM-based comparative models (including LoRA, SAM-Med2D, VPT, and MedSAM in Table 9).

[0139] 1.11 Parameter Efficiency Analysis Table 10 compares the computational efficiency of different methods. The NeoPromptFormer segmentation model updates only 4.6% of the total parameters (4.15M out of 89.99M), yet achieves competitive performance. This parameter efficiency is comparable to other PEFT methods (LoRA: 3.1%, VPT: 2.9%), while maintaining strong performance on BOBs (Table 1). The slightly higher number of trainable parameters reflects the addition of the AgePrompt module and the optional LLM warm-up embedding (LLM-init; offline Qwen3-4B vectors). Memory usage (1046 MiB) and inference time (1.97 ms / slice) are comparable to baseline methods, supporting feasibility for resource-constrained research workflows; additional end-to-end validation is required for clinical deployment.

[0140] 1.12 Qualitative Visualization The qualitative research protocol of this experiment follows the principles of individual subject reports and authentic preservation of test evidence, and includes clear diagnoses of error and uncertainty.

[0141] Qualitative case selection scheme (fixed, non-random selection): All qualitative cases are selected solely from the retained test set using a deterministic scheme. • Random-5: Five randomly selected test subjects (fixed factor) are used to demonstrate typical behavior.

[0142] • Best-2 / Worst-2: The two best and two worst subjects ranked by each subject's Dice score (BOBs: mDice; BONBID-HIE: lesion Dice) to demonstrate robustness and failure mode.

[0143] • Hard case set: (BOBs) samples with minDice tissue class in the slides; (BONBID-HIE) subjects in the minimum lesion group (lesion volume <0.1%).

[0144] Qualitative Dice Consistency with Tables: Qualitative Panels ( Figure 17 and Figure 18 The Dice values ​​displayed are clearly labeled as the slice Dice for that slice; subject-level indicators are shown in Tables 1 and 2. If slice Dice is displayed, this experiment will additionally report the corresponding subject-level Dice for the same subject in the figure caption. Figure 17 In the middle, from left to right, are: T1w, T2w, actual value, VPT prediction result, and NeoPromptFormer prediction result. The Dice values ​​displayed in the VPT and NeoPromptFormer panels are slice-level data. Figure 18The middle row is arranged according to the deterministic protocol based on the fixed test: highest gain cases, median cases, high-difficulty cases (<0.1% lesion burden), and failure cases. Columns display the input ADC, GT, MedicalSAM adapter (strongest baseline), NeoPromptFormer, NeoPromptFormer+TTA, and false positive / false negative diagnoses. Each row panel lists the lesion burden (% brain tissue), slice Dice (baseline / our / our+TTA), and the corresponding subject-level lesion Dice.

[0145] Visual design standards (applicable to) Figure 17 – Figure 22 For each demonstration case, this experiment provides: (i) input MRI, (ii) GT, (iii) representative baseline, (iv) our, (v) error plot (FP / FN), and (vi) uncertainty / probability (entropy or p). max ).

[0146] 1.13 Visualization of Component Analysis All component analysis visualization results are based on real evidence from the dataset and auditable generation scripts.

[0147] Age-related evidence ( Figure 19 This demonstrates the age-perceived behavior of the cue library, including age-performance trends and learned cue weight trajectories. Specifically, in... Figure 19 In the image, (a) shows a comparison of NeoPromptFormer (with AgePrompt enabled) and fixed cue baseline checkpoints on individual mDice and PMA. (b) shows the learned cue library weight trajectory calculated based on checkpoints trained using real PMA values. Section (c) shows the decay of the age-performance trend as indicated by the age label replacement comparison.

[0148] PEFT-MAE evidence ( Figure 20 This experiment is entirely data-driven: Real encoder features are projected from preserved BOBs and BONBID-HIE slices, before and after PEFT-MAE, and quantitative domain separability scores are reported. In this setting, the linear probe domain AUC saturates near 1.0, making the contour plot a more sensitive indicator of cross-domain overlap. Figure 20 In the figure, (a) and (b) show the PCA projection of encoder features before and after PEFT-MAE processing (BOBs vs. BONBID-HIE); (c) shows the domain separability metrics (linear probe domain AUC and contour coefficient), with the domain AUC saturating at 1.0 in both settings, while the contour coefficient is used as a sensitive overlap metric in this comparison.

[0149] Figure 21 This provides evidence of real-world slice adaptation during testing after optimization on the BONBID-HIE test data. This experiment compares the prediction results before and after TTA and visualizes the probability change graph | pafter. pbefore|, and reported the entropy plot and optimization trajectory between test steps. BONBID lesion analysis ( Figure 22 ). Among them, in Figure 21 In the diagram, (a) and (b) show the comparison between the predicted results and the true contour (green) before and after TTA; (c) shows the probability change graph |p after p before |; (d)-(e) show the entropy plots before and after adaptation; (f) shows the changes in the optimized trajectory (energy term, entropy term, edge term) during the refinement step.

[0150] Figure 22 This paper summarizes the lesion analysis on the retained BONBID-HIE test data. It reports precision-recall curves with bootstrap confidence intervals, Dice and binning statistics stratified by lesion size, and diagnoses including baseline, this method, this method versus TTA, and FP / FN. Figure 22 In the image, (a) shows the precision-recall curves of NeoPromptFormer, MedicalSAMAdapter, and SAM-Med2D, with the AP value and bootstrap 95% confidence interval labeled in the legend; (b) shows the Dice values ​​of the slices stratified by lesion size, with n samples counted in each bin; (c) shows the qualitative analysis panel for real cases: input ADC, GT, baseline, current data, current data + TTA, and false positive / false negative plot (FP=yellow, FN=cyan). For ease of reading, the panel labels are placed outside the image area.

[0151] II. Discussion Cross-task performance: In the BOBs multi-tissue segmentation task, NeoPromptFormer+LLM achieved the best mDice and highest minDice values ​​among all comparison methods (Table 1), indicating its robust performance across different tissue categories. In the BONBID-HIE (uniform two-dimensional protocol) task, NeoPromptFormer ranked first in all three main metrics (lesion Dice, PR-AUC, Sens@Spec97).

[0152] Among all comparison methods (Table 2), the paired Wilcoxon test showed a significant improvement in Dice scores compared to representative SAM-based comparison methods (including the Medical SAM Adapter). Under the unified BONBID protocol, except for Dice-only collapse, the Dice scores in the prompt / age / loss ablation group remained consistently within the range of 0.22–0.24, validating the robustness of the master operation point conclusions. It is worth noting that while time refinement without parameter tuning can improve some difficult cases, its effect is not uniformly monotonically across all subjects with small lesions; therefore, it should be considered an optional post-hoc analysis rather than a guarantee of global improvement.

[0153] Diagnostic and Ablation Protocols: Section 1.7 reports on univariate experiments employing matched visual and statistical evidence. Both the main table and the module / loss ablation table used a single Bonbidhie subject protocol, which eliminated metric definition drift and made component comparisons auditable. Multifactor tables were used for the main claims (Tables 3 and 6), while the seed42 module / loss scan was interpreted as diagnostic trend evidence.

[0154] Clinical significance of parameter efficiency: NeoPromptFormer updates only 4.6% of the total parameters while maintaining competitive performance. This parameter efficiency reduces adaptation costs and storage overhead when maintaining multi-site specific models, making it particularly attractive for fine-tuning large backbone networks with limited labeled neonatal data. However, actual clinical deployment requires consideration of factors that are not yet fully validated, such as absolute runtime, memory footprint, robustness to scanner / site changes, and workflow integration.

[0155] Limitations and Prospective Study: While the two-dimensional slice analysis method used in this experiment can efficiently utilize the two-dimensional basic model, it may miss long-range three-dimensional contextual information that is crucial for volume consistency. The 2.5D input partially addresses this issue but remains limited to local context. Key areas requiring validation include: comprehensive volume adaptation, cross-site robustness assessment, and testing of a wider range of lesion focusing protocols.

[0156] III. Conclusion This application proposes the NeoPromptFormer segmentation model framework, a parametrically efficient neonatal brain MRI segmentation scheme specifically designed to address the unique challenges posed by the rapidly changing anatomy and limited training data in this clinical field. The scheme integrates four complementary components: (1) a PEFT-MAE module with pre-adaptation techniques to bridge the knowledge gap between the natural and medical domains; (2) an AgePrompt module (optionally warmed up via cue embeddings initialized with Qwen3-4B) for developmental condition training; (3) a TQ-Decoder module supporting a flexible multi-task decoder; and (4) a TQ-Decoder module that adapts to untuned testing for image refinement.

[0157] Using two early-life brain MRI benchmarks—BOBs for multi-tissue segmentation and BONBID-HIE for detecting hypoxic-ischemic encephalopathy (HIE) lesions—this application presents the NeoPromptFormer segmentation model framework, which exhibits robust performance with only 4.6% of total parameters updated. Its performance in both BOBs and BONBID-HIE tests outperforms traditional fully supervised baseline methods (Tables 1-2). Under a unified BONBID individualized assessment scheme (lesion Dice value, PRAUC, and Sens@Spec97 metrics with fixed segmentation / thresholds), the NeoPromptFormer segmentation model framework ranks first among key lesion assessment metrics and significantly improves the Dice value compared to most comparative models based on adaptive multimodal (SAM). Section 1.7 further provides a stable interpretation at the component level, avoiding inconsistencies in metrics. These results suggest that model-based adaptation incorporating developmental conditions is a potential direction for early-life neuroimaging analysis with clinical translational potential.

[0158] In summary, the neonatal brain MRI image segmentation method provided in this application offers an efficient and age-aware adaptive strategy for neonatal brain MRI segmentation. It utilizes prior knowledge from the base model and efficiently adapts to neonatal brain MRI under limited supervised labeling conditions. Furthermore, it maintains robustness across different developmental stages and segmentation tasks, thereby enhancing the robustness of neonatal brain MRI segmentation in tissue and microlesion environments.

[0159] Figure 23 A structural block diagram of a neonatal brain MRI image segmentation apparatus according to an embodiment of this application is shown. Figure 23 As shown, the device may include: The first data receiving unit 210 is used to acquire a sample dataset, which includes multiple neonatal brain MRI images, wherein each neonatal brain MRI image contains its corresponding label mapping map, and the label mapping map contains the neonatal postmenopausal age (PMA). The first preprocessing unit 220 is used to perform two-dimensional slicing on each neonatal brain MRI image in the sample dataset to obtain the processed sample dataset. Model building unit 230 is used to construct the NeoPromptFormer segmentation model based on a promptable visual backbone network. The NeoPromptFormer segmentation model includes a PEFT-MAE module, an Age-Prompt module, and a TQ-Decoder module. The segmentation prediction process of the NeoPromptFormer segmentation model is as follows: the PEFT-MAE module uses a parameter-efficient mask autoencoder pre-adaptation strategy to perform parameter-efficient fine-tuning of the encoding process of the input image based on the instantiated age prompt words output by the Age-Prompt module; the Age-Prompt module dynamically generates instantiated age prompt words from a learnable age conditional prompt library based on the PMA of the input image, and transmits the instantiated age prompt words to the PEFT-MAE module for encoding adjustment; the TQ-Decoder module generates the initial segmentation prediction result of the input image based on the output features of the PEFT-MAE module, and performs test optimization of the initial segmentation prediction result without parameter tuning under differentiable dissection prior conditions for the prompt words or query variables of the input image, and outputs the optimized final segmentation prediction result. The model training unit 240 is used to train the NeoPromptFormer segmentation model using the processed sample dataset to obtain the trained NeoPromptFormer segmentation model. The second data receiving unit 250 is used to acquire MRI images of the newborn's brain to be tested; The second preprocessing unit 260 is used to perform two-dimensional slicing on the neonatal brain MRI image to be tested, so as to obtain the neonatal brain MRI image after two-dimensional slicing. The model prediction unit 270 is used to input the neonatal brain MRI image after two-dimensional slicing into the NeoPromptFormer segmentation model for segmentation processing to obtain the final segmentation prediction result of the neonatal brain MRI image to be tested.

[0160] The functions of each unit in the neonatal brain MRI image segmentation device of this application embodiment can be found in the corresponding description in the above method, and will not be repeated here.

[0161] Figure 24A structural block diagram of a computer device according to an embodiment of this application is shown. Figure 24 As shown, the computer device includes a memory 310 and a processor 320. The memory 310 stores instructions, which are loaded and executed by the processor 320 to implement the neonatal brain MRI image segmentation method in the above embodiment. The number of memories 310 and processors 320 can be one or more.

[0162] The computer device also includes: The communication interface 330 is used to communicate with external devices and perform data exchange and transmission.

[0163] If the memory 310, processor 320, and communication interface 330 are implemented independently, they can be interconnected via a bus to communicate with each other. This bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. This bus can be divided into address bus, data bus, control bus, etc. For ease of representation, Figure 24 The bus is represented by a single thick line, but this does not mean that there is only one bus or one type of bus.

[0164] Optionally, in a specific implementation, if the memory 310, processor 320 and communication interface 330 are integrated on a single chip, the memory 310, processor 320 and communication interface 330 can communicate with each other through an internal interface.

[0165] This application provides a computer-readable storage medium storing a computer program. When the computer program is run on a computer, it implements the method provided in this application.

[0166] This application also provides a chip, which includes a processor for calling and executing instructions stored in a memory, causing a communication device with the chip installed to perform the method provided in this application.

[0167] This application also provides a chip, including: an input interface, an output interface, a processor, and a memory. The input interface, output interface, processor, and memory are connected through an internal connection path. The processor is used to execute code in the memory. When the code is executed, the processor is used to execute the method provided in the application embodiment.

[0168] It should be understood that the aforementioned processor can be a Central Processing Unit (CPU), or other general-purpose processors, Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field-Programmable Gate Arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. General-purpose processors can be microprocessors or any conventional processor. It is worth noting that the processor can be a processor supporting Advanced Reduced Instruction Set Machines (ARM) architecture.

[0169] Further, optionally, the aforementioned memory may include read-only memory and random access memory, and may also include non-volatile random access memory. The memory may be volatile or non-volatile, or may include both. Non-volatile memory may include read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), or flash memory. Volatile memory may include random access memory (RAM), which serves as an external cache. Many forms of RAM are available by way of example, but not limitation. Examples include static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDR SDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous linked dynamic random access memory (SLDRAM), and direct rambus RAM (DR RAM).

[0170] In the above embodiments, implementation can be achieved, in whole or in part, through software, hardware, firmware, or any combination thereof. When implemented in software, it can be implemented, in whole or in part, as a computer program product. A computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the flow or function according to this application is generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transferred from one computer-readable storage medium to another.

[0171] In the description of this specification, the references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of this application. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification, as well as the features of those different embodiments or examples.

[0172] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of that feature. In the description of this application, "a plurality of" means two or more, unless otherwise explicitly specified.

[0173] Any process or method description in the flowchart or otherwise herein can be understood as representing a module, segment, or portion of code comprising one or more executable instructions for implementing a particular logical function or process. Furthermore, the scope of the preferred embodiments of this application includes additional implementations in which functions may be performed not in the order shown or discussed, including substantially simultaneously or in reverse order depending on the functionality involved.

[0174] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a sequenced list of executable instructions for implementing logical functions, and can be embodied in any computer-readable medium for use by, or in conjunction with, an instruction execution system, apparatus or device (such as a computer-based system, a processor-included system or other system that can fetch and execute instructions from, an instruction execution system, apparatus or device).

[0175] It should be understood that various parts of this application can be implemented using hardware, software, firmware, or a combination thereof. In the above embodiments, multiple steps or methods can be implemented using software or firmware stored in memory and executed by a suitable instruction execution system. All or part of the steps of the methods in the above embodiments can be implemented by a program instructing related hardware, the program being stored in a computer-readable storage medium, which, when executed, includes one or a combination of the steps of the method embodiments.

[0176] Furthermore, the functional units in the various embodiments of this application can be integrated into a processing module, or each unit can exist physically separately, or two or more units can be integrated into a module. The integrated module can be implemented in hardware or as a software functional module. If the integrated module is implemented as a software functional module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. This storage medium can be a read-only memory, a disk, or an optical disk, etc.

[0177] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any person skilled in the art can easily conceive of various variations or substitutions within the technical scope disclosed in this application, and these should all be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. A method for segmenting MRI images of a newborn's brain, characterized in that, include: Obtain a sample dataset, which includes multiple neonatal brain MRI images, wherein each neonatal brain MRI image contains its corresponding label mapping map, and the label mapping map contains the neonatal postmenopausal age (PMA). Each neonatal brain MRI image in the sample dataset is subjected to two-dimensional slicing to obtain the processed sample dataset; Based on a promptable visual backbone network, a NeoPromptFormer segmentation model is constructed. This model includes a PEFT-MAE module, an Age-Prompt module, and a TQ-Decoder module. The segmentation prediction process of the NeoPromptFormer model is as follows: The PEFT-MAE module employs a parameter-efficient masked autoencoder pre-adaptation strategy to fine-tune the encoding process of the input image based on the instantiated age prompts output by the Age-Prompt module. The Age-Prompt module dynamically generates instantiated age prompts from a learnable age conditional prompt library based on the PMA of the input image and transmits these prompts to the PEFT-MAE module for encoding adjustment. The TQ-Decoder module generates an initial segmentation prediction result for the input image based on the output features of the PEFT-MAE module. Under differentiable dissection prior conditions, the initial segmentation prediction result is tested and optimized without parameter tuning based on the prompts or query variables of the input image, and the optimized final segmentation prediction result is output. The NeoPromptFormer segmentation model is trained using the processed sample dataset. Obtain MRI images of the newborn's brain; The neonatal brain MRI image to be tested is processed into two-dimensional slices to obtain a neonatal brain MRI image after two-dimensional slice processing. The neonatal brain MRI image after two-dimensional slicing is input into the NeoPromptFormer segmentation model for segmentation processing to obtain the final segmentation prediction result of the neonatal brain MRI image to be tested.

2. The method according to claim 1, characterized in that, Each neonatal brain MRI image in the sample dataset is subjected to two-dimensional slicing to obtain the processed sample dataset, which includes: Two-dimensional slices are made for each neonatal brain MRI image in the sample dataset to obtain multiple slices corresponding to each neonatal brain MRI image; By stacking adjacent slices from the plurality of slices, each newborn brain MRI image is obtained after two-dimensional slicing. Based on each neonatal brain MRI image after two-dimensional slicing, the processed sample dataset is obtained.

3. The method according to claim 1, characterized in that, The PEFT-MAE module includes a lightweight modality adapter, a LoRA adapter, and a pre-trained ViT image encoder and MAE decoder from the SAM model. LoRA refers to low-rank adaptation. The PEFT-MAE module employs a parameter-efficient masked autoencoder pre-adaptation strategy. Based on the instantiated age prompts output by the Age-Prompt module, the encoding process of the input image is parameter-efficiently fine-tuned, including: The input image is mapped to the basic visual backbone network of the ViT image encoder using the lightweight modal adapter. The ViT image encoder performs feature encoding on the input image based on the instantiated age prompt words output by the Age-Prompt module; The LoRA adapter is used to adaptively adjust each attention projection matrix in the selected basic visual backbone network of the ViT image encoder; The MAE decoder employs a parameter-efficient mask autoencoding pre-adaptation strategy to perform parameter fine-tuning on the encoding process of the ViT image encoding.

4. The method according to claim 3, characterized in that, The efficient fine-tuning of parameters in the encoding process of the ViT image encoding, using the MAE decoder and the parameter-efficient mask autoencoder pre-adaptation strategy, includes: For each slice in the input image, a portion of the image block in each slice is randomly masked using the MAE decoder; The masked image blocks in each slice are reconstructed using the MAE decoder. During this process, the loss between the reconstructed image blocks and the original image blocks in each slice is minimized. Only the parameters of the lightweight modality adapter, the instantiated age cue, and the LoRA adapter are updated. After pre-adaptation, only the PEFT parameters adapted during the ViT image encoding process are retained. PEFT refers to parameter efficient fine-tuning.

5. The method according to claim 1, characterized in that, The Age-Prompt module dynamically generates instantiated age prompts from a learnable age conditional prompt library based on the PMA of the input image, and transmits the instantiated age prompts to the PEFT-MAE module for encoding adjustment, including: The PEFT-MAE module predefines M basic age prompt word sets corresponding to each basic visual backbone network; The Age-Prompt module is used to map the PMA of the input image into an M-dimensional hybrid weight vector through a multilayer perceptron (MLP). Then, the M basic age prompt word sets are weighted and summed according to the hybrid weight vector to obtain the instantiated age prompt word. The Age-Prompt module is used to transmit the instantiated age prompt word to the PEFT-MAE module for encoding adjustment.

6. The method according to claim 5, characterized in that, The method includes: The Age-Prompt module is used to apply smoothness regularization constraints to adjacent age prompts in the instantiated age prompts to avoid discontinuous age prompt switching and to encourage developmental continuity.

7. The method according to any one of claims 1-6, characterized in that, The TQ-Decoder module generates an initial segmentation prediction result for the input image based on the output features of the PEFT-MAE module. Then, under differentiable anatomical prior conditions, the initial segmentation prediction result is tested and optimized without parameter tuning based on the cue or query variables of the input image. The optimized final segmentation prediction result includes: The TQ-Decoder module uses K learnable category queries and performs cross-attention decoding with the instantiated age prompt words through a Transformer decoder to generate K refined category queries. The TQ-Decoder module is used to generate an initial segmentation prediction result for the input image based on the K refined category queries; During the model inference phase, the TQ-Decoder module is used to perform small residual updates on the category query offset, and the weight of the instantiated age prompt is fixed to the output of the PEFT-MAE module. Then, the target supervision function is used to supervise the initial segmentation prediction result, and the optimized final segmentation prediction result is output. The category query offset is the difference between each learnable category query and its corresponding refined category query.

8. A device for segmenting MRI images of a newborn's brain, characterized in that, include: The first data receiving unit is used to acquire a sample dataset, which includes multiple neonatal brain MRI images, wherein each neonatal brain MRI image contains its corresponding label mapping map, and the label mapping map contains the neonatal postmenopausal age (PMA). The first preprocessing unit is used to perform two-dimensional slicing on each of the neonatal brain MRI images in the sample dataset to obtain the processed sample dataset. The model building unit is used to construct the NeoPromptFormer segmentation model based on a promptable visual backbone network. The NeoPromptFormer segmentation model includes a PEFT-MAE module, an Age-Prompt module, and a TQ-Decoder module. The segmentation prediction process of the NeoPromptFormer segmentation model is as follows: The PEFT-MAE module employs a parameter-efficient masked autoencoder pre-adaptation strategy; the encoding process of the input image based on the instantiated age prompts output by the Age-Prompt module is parameterized. Efficient fine-tuning: The Age-Prompt module dynamically generates instantiated age prompts from a learnable age conditional prompt library based on the PMA of the input image, and transmits the instantiated age prompts to the PEFT-MAE module for encoding adjustment; the TQ-Decoder module generates an initial segmentation prediction result for the input image based on the output features of the PEFT-MAE module, and performs parameter-free test optimization on the initial segmentation prediction result for the prompts or query variables of the input image under differentiable dissection prior conditions, and outputs the optimized final segmentation prediction result; The model training unit is used to train the NeoPromptFormer segmentation model using the processed sample dataset to obtain a trained NeoPromptFormer segmentation model. The second data receiving unit is used to acquire MRI images of the newborn's brain. The second preprocessing unit is used to perform two-dimensional slicing on the neonatal brain MRI image to be tested, so as to obtain a neonatal brain MRI image after two-dimensional slicing. The model prediction unit is used to input the neonatal brain MRI image after two-dimensional slicing into the NeoPromptFormer segmentation model for segmentation processing, and obtain the final segmentation prediction result of the neonatal brain MRI image to be tested.

9. A computer device, characterized in that, include: A memory and a processor, wherein the memory stores instructions which are loaded and executed by the processor to implement the method as described in any one of claims 1-7.

10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when run on a computer, implements the method as described in any one of claims 1-7.