X-ray imaging apparatus, medical image processing apparatus, and medical image processing method
A deep learning model with supervised cross-attention layers and structured text prompts addresses spurious correlations in latent diffusion models, enhancing the alignment of text and image regions for improved medical image processing.
Patent Information
- Application Number
- JP2026082973
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2025-05-16
- Filing Date
- 2026-05-18
- Publication Date
- 2026-11-27
AI Technical Summary
Existing latent diffusion models for medical image processing often learn spurious correlations between text data and image regions, leading to unreliable phrase localization and annotation due to spatial leakage of cross-attention activations.
Implement a deep learning model with cross-attention layers supervised by spatial landmark atlases and structured text prompts to align text data with image regions, using a loss function to adjust text encoding and improve spatial consistency.
Enhances the reliability of medical image processing by ensuring that text data aligns with anatomical image regions, improving localization accuracy and reducing spurious correlations.
Smart Images

Figure 2026185909000001_ABST
Abstract
Description
[Technical Field]
[0001] Embodiments disclosed in this specification and the drawings relate to an X-ray imaging apparatus, a medical image processing apparatus, and a medical image processing method for learning and applying a model based on medical image data. [Background Art]
[0002] It is known to use latent diffusion models to perform text-guided image generation. Latent diffusion models can also be used to improve systems that generate or use medical image data. However, at least some of such known approaches may learn spurious correlations, and the text data may not align with spatial image regions. [Prior Art Documents] [Patent Documents]
[0003] [Patent Document 1] Japanese Patent No. 7691548 [Summary of the Invention] [Problem to be Solved by the Invention]
[0004] Accordingly, one of the problems to be solved by the embodiments disclosed in this specification and the drawings is to train the model such that the text data aligns with the image regions. However, the problems to be solved by the embodiments disclosed in this specification and the drawings are not limited to the above problems. Problems corresponding to the effects of the configurations described in the embodiments below may be considered as other problems. [Means for Solving the Problems]
[0005] The medical image processing method according to the embodiment comprises a deep learning model that includes one or more cross-attention layers for localizing text data with respect to medical image data, and supervised learning that includes supervising the one or more cross-attention layers using either or both of the terms and spatial landmark atlas derived from the text data and included in the vocabulary. [Effects of the Invention]
[0006] According to the present invention, a model can be trained so that text data and image regions are consistent. [Brief explanation of the drawing]
[0007] [Figure 1] This is a schematic diagram of a device relating to one embodiment of the present invention. [Figure 2] This is a schematic representation of the application of a latent diffusion model to medical image processing according to one embodiment of the present invention. [Figure 3] This is a schematic representation of another application of the latent diffusion model to medical image processing according to one embodiment of the present invention. [Figure 4A] This is a schematic diagram of a system for another application of the latent diffusion model to medical image processing according to one embodiment of the present invention. [Figure 4B] This is a schematic diagram of the supervision process for applying a latent diffusion model according to one embodiment of the present invention. [Figure 5] This is a comparative example of exemplary results obtained by applying different latent diffusion models to medical image processing according to one embodiment of the present invention. [Figure 6] This is a comparative example of the performance of a supervised latent diffusion model having structured prompt inputs according to one embodiment of the present invention, and the performance of a frozen LDM having unstructured and structured inputs. [Figure 7] This is a flowchart showing a medical image processing method according to one embodiment of the present invention. [Modes for carrying out the invention]
[0008] A data processing device 20 according to one embodiment is schematically shown in Figure 1. In this embodiment, the data processing device 20 is configured to process medical data. In other embodiments, the data processing device 20 may be configured to process any other suitable data.
[0009] The data processing device 20 includes an arithmetic unit 22, which in this example is a personal computer (PC) or workstation. The arithmetic unit 22 is connected to a display screen 26 or other display device and to an input device such as a computer keyboard, touchscreen and / or mouse, or a plurality of input devices 28.
[0010] The computing unit 22 is configured to acquire a dataset from the data storage unit 30. The dataset is acquired or generated using any suitable device or from any suitable source. In some embodiments, at least a portion of the data may include, or be determined from, medical image data acquired, for example, using a scanner 24.
[0011] The scanner 24 may be configured to generate medical image data that may include two-dimensional, three-dimensional, or four-dimensional data in any image modality. For example, the scanner 24 may include a magnetic resonance (MR or MRI) scanner, a CT (computed tomography) scanner, a cone-beam CT scanner, an X-ray scanner, an ultrasound scanner, a PET (positron emission tomography) scanner, or a SPECT (single-photon emission computed tomography) scanner.
[0012] Medical image data may include or be associated with additional data. This additional data may include text data or other non-image data, such as medical reports, including radiology reports relating to the medical image data. In some examples, the medical image data may include chest X-ray (CXR) images. The computing unit 22 may receive data from one or more additional data storage units (not shown) instead of or in addition to the data storage unit 30. For example, the computing unit 22 may receive medical image data from one or more remote data storage units (not shown) that may form part of an image archiving and communication system (PACS) or other information system.
[0013] The arithmetic unit 22 provides processing resources for processing data automatically or semi-automatically. The arithmetic unit 22 includes a processing unit 32. The processing unit 32 includes an image processor 34 for processing medical image data, a prompt processor 36 for processing additional data, a data processing circuit 40 configured to apply a model to the processed medical image data and related data to perform localization based on the medical image data, and an interface circuit 38 configured to acquire user or other input and / or output the results of data processing.
[0014] For example, the interface circuit 38 may be configured to provide medical image data enhanced by localization data for display on the display screen 26, or for storage in, for example, the data storage unit 30 or one or more remote data storage units (not shown).
[0015] In this embodiment, circuits 34, 36, and 38 are each implemented in the arithmetic unit 22 by a computer program having computer-readable instructions executable to perform the method of this embodiment. However, in other embodiments, the various circuits may be implemented as one or more ASICs (Application-Specific Integrated Circuits) or FPGAs (Field-Programmable Gate Arrays).
[0016] The arithmetic unit 22 also includes other components of the computer, such as a hard drive, RAM, ROM, data bus, operating system including various device drivers, and hardware devices including a graphics card. For clarity, these components are not shown in Figure 1.
[0017] The data processing device 20 of FIG. 1 is configured to execute the methods shown and / or described below.
[0018] In at least some embodiments, medical image data is received from a medical image scanner, an image archiving and communication system (PACS), a radiology information system (RIS), an electronic medical record system (EMR), or other medical data repository. The medical image data may include, for example, X-ray image data, computed tomography image data, magnetic resonance image data, ultrasound image data, PET image data, SPECT image data, or other medical image data.
[0019] In at least some embodiments, localization information generated by the model is output in association with medical image data. For example, the localization information may be displayed as an overlay on a medical image on a display device, stored as metadata associated with the medical image, stored as a secondary capture image, stored as an annotation object, stored as a segmentation object, or otherwise stored on a computer-readable storage medium in association with medical image data.
[0020] In at least some embodiments, the output is spatially aligned with a coordinate system or pixel coordinate space of the medical image data. For example, a heat map generated from a cross-attention map may be resized, resampled, or transformed to match the spatial dimensions of the medical image before being displayed or stored.
[0021] Figures 2 and 3 illustrate the use of a diffusion model for phrase grounding of medical image data, such as that generated or used by the apparatus of Figure 1. The latent diffusion model (LDM) includes a cross-attention mechanism that can be used to match visual and text features. While the latent diffusion model is useful and is described herein, this disclosure is not limited to the latent diffusion model, and other models with cross-attention mechanisms, particularly those applicable to image and text data, can be used.
[0022] In the examples in Figures 2 and 3, LDM202 is used in a zero-shot manner, i.e., without training on the target task, and as a result, the model weights are frozen. Specifically, LDM202 receives an input pair consisting of a medical image 204 (corresponding to the medical image data in the example in Figure 1) and a text prompt 206 related to the medical image 204.
[0023] In Figure 2, examples of input pairs include an input pair containing a medical image 204 showing the morphology of a chest X-ray image and the text prompt "bibasilar opacities," and another input pair containing a different medical image 204', also showing a chest X-ray image, and a different text prompt 206', "very small pleural effusions."
[0024] The output of LDM202 is heatmaps 208 and 208' corresponding to each input pair. The heatmaps show the degree of consistency between text prompts 206 and 206' and the corresponding medical images 204 and 204'. This consistency indicates the likelihood that the text prompts 206 and 206' refer to the corresponding parts of the medical images 204 and 204'. Heatmaps 208 and 208' are scaled to match the corresponding medical images 204 and 204' and are overlaid on a display screen, for example, 26 in Figure 1, for display purposes.
[0025] The LDM202 includes a visual encoder that converts medical images 204 and 204' into their original latent representations. The LDM202 applies a forward-diffusing process that iteratively adds noise to the latent representations of medical images 204 and 204'. That is, it first adds noise to the original latent representations directly generated from medical images 204 and 204', and then iteratively generates further latent representations leading to the final latent representation, i.e., the noisiest representation.
[0026] Subsequently, LDM202 applies a despreading process that iteratively removes noise from the latent representation, starting from the final latent representation, until a reconstructed version of the original latent representation is recovered. The spreading and despreading processes are performed by an AI model, such as a U-Net model, appropriately configured to predict the noise added in each iteration. The reconstructed image is finally generated using a visual decoder from the recovered reconstructed version of the original latent representation output by the despreading process.
[0027] The LDM202 includes a cross-attention mechanism comprising multiple cross-attention layers, which is configured to capture the interaction between medical images 204, 204', i.e., visual streams, and associated text prompts 206, 206', i.e., text streams.
[0028] In the example, text prompts 206, 206' are split into tokens and encoded into latent representations (text features) using a text encoder. These are used to provide context in each cross-attention layer of the U-Net. In the example, the latent representations (text features) are used to generate keys and values, and the latent representations generated from the image are used to extract queries. Essentially, the queries are high-level descriptors of the visual content, the keys are high-level descriptors of the text content, and the values are more detailed descriptors of the text content.
[0029] A suitable cross-attention mechanism can be implemented based on, for example, the Softmax function, but other functions can also be used. A cross-attention map is calculated at each layer and each time step / iteration. This results in N × T cross-attention maps, where N is the number of cross-attention layers and T is the number of diffusion iterations (number of time steps). Each cross-attention map is different from the others depending on the visual features and noise levels in each latent representation.
[0030] The processes performed in at least some embodiments are not actually feasible as mental processes. For example, such processes may include encoding medical image data into latent image representations, performing diffusion or dediffusion processing over multiple time steps, extracting intermediate cross-attention maps from multiple cross-attention layers, generating a synthetic heatmap derived from an atlas, calculating one or more loss terms based on the intermediate cross-attention maps and the synthetic heatmap, and adjusting model parameters such as token embeddings. These processes involve numerical tensor operations over image features, text features, latent representations, and spatial attention maps, and are performed by one or more processors.
[0031] In at least some embodiments, the model processes multiple cross-attention maps generated at different network layers and / or different spreading time steps. Aggregating, normalizing, resizing, comparing, and learning such maps are computer implementations of high-dimensional data and do not correspond to steps that can be performed in the human mind.
[0032] To perform phrase grounding using a given medical image and prompt as input, multiple intermediate cross-attention maps are extracted as heatmaps from an AI model, such as U-Net. The multiple heatmaps extracted from the cross-attention layer are aggregated to form aggregated heatmaps 208 and 208'. The aggregated heatmap should be highly activated in the region of interest specified by the prompt.
[0033] In some examples, only a subset of intermediate cross-attention maps is used to form the aggregated heatmaps 208, 208'. For example, several M intermediate layers, where M is less than the total number of intermediate cross-attention maps, and which do not include at least the first or first few and the last or last few intermediate cross-attention maps. The selected cross-attention maps may be normalized so that their intensity spans the range [0,1] and resized to match the spatial dimensions of the medical image. The output aggregated heatmaps 208, 208' are formed by averaging the maps across layers, time steps, and tokens.
[0034] Figures 2 and 3 show examples of results obtained by applying phrase localization to enhance medical images using this method. In these figures, aggregated heatmaps 208 and 208' are shown with dark shading, and target lesions are indicated by boxes.
[0035] In Figure 2, the heatmap correlates well with the target lesions indicated by the boxes, demonstrating the validity of this method. On the other hand, in the example in Figure 3, the heatmap does not correlate closely with the left upper lobe of the lung.
[0036] While we do not wish to be constrained by any particular theory, standard text-guided LDM networks, while often capable of producing good results, are not guaranteed to learn the cross-modal attention mechanism that accurately aligns text tokens with spatial image regions. Rather, spurious correlations with other text tokens appearing in similar contexts may be learned. This is likely to occur when using diverse vocabulary. This can be problematic when using intermediate latent representations for downstream tasks such as phrase grounding, which require precise localization.
[0037] A technical challenge addressed by at least some embodiments is that cross-attention activation in pre-trained or frozen text-guided image models, such as latent diffusion models, may be spatially diffuse or leak into image regions that do not correspond to the anatomical location or lesion described by the text prompt. Such spatial leakage can reduce the reliability of phrase localization, image annotation, candidate lesion enhancement, and other downstream medical image processing tasks.
[0038] At least some embodiments address this technical challenge by generating spatially supervised signals, such as synthetic heatmaps or positional distributions, from structured prompt terms and atlases, and using these spatially supervised signals to supervise intermediate cross-attention maps of the model. This supervision can improve the spatial specificity of cross-attention activations and enhance the alignment between text tokens and anatomical image regions represented in medical image data.
[0039] This improvement is not merely about presenting information. Rather, in at least some embodiments, the parameters of the text encoding section of a model, such as a token embedding or text encoder, are adjusted based on a loss function that compares an intermediate cross-attention map extracted from one or more cross-attention layers with a synthetic heatmap derived from an atlas. The resulting trained model can generate localization information that is spatially aligned with medical image data, such as heatmaps, bounding boxes, segmentation, masks, or other image spatial localization outputs.
[0040] As a solution, to improve the reliability of applying deep learning representations using spatial or other cross-attention models, not limited to diffusion models, to the localization of lesions in medical images, such as phrase localization, a text prompt coding mechanism can be trained by supervising cross-modal attention maps using atlases and / or vocabulary.
[0041] In the example, the atlas may be a simple spatial landmark atlas of relevant anatomical structures. The atlas includes mapping from descriptors to relevant locations in images. In the example, the spatial landmark atlas may be identified from prompts by identifying terms related to one or more of the following: location, lesion, anatomical structure, etc., which are specified in the vocabulary. Using the atlas, terms extracted from prompts can be mapped to relevant locations in the atlas, for example, using a lookup table or other mapping mechanism.
[0042] In the example, the relevant locations may include distributions such as bounding boxes or Gaussian distributions, pseudo-Gaussian distributions, or similar spread distributions. By applying a distribution to a location, for example, around the centroid, a composite heatmap can be substantially created.
[0043] The cross-attention map is used with an appropriate loss function that represents the degree of deviation of the cross-attention map from the synthetic heatmap generated for that text prompt, allowing the text stream to be learned.
[0044] Regarding vocabulary, it may include a predefined standard vocabulary related to relevant medical reports or other reports associated with relevant anatomical structures, such as radiology reports. Advantageously, intermediate heatmaps and / or average heatmaps (which may optionally be weighted averages or other weighted combinations) may be used not only for downstream tasks, such as phrase localization, or for annotation or augmentation of medical images for display, but also for supervision.
[0045] Figure 4A shows an example of this supervision of a cross-attention layer to ensure better alignment between text prompt tokens and correct anatomical image locations.
[0046] Figure 4A shows a medical image data processing system 400 (medical image processing device) that implements an AI model such as a modified LDM or other deep learning model using spatial cross-attention. When in use, the system 400 receives medical image data 405, such as a chest X-ray (CXR) or other appropriate medical image. The medical image data 405 corresponds to medical image 204.
[0047] In the example, system 400 may be implemented by the computing unit 22 of Figure 1 and may include any of the features described in relation thereto. System 400 is configured to convert medical image data 405 into a latent representation using a suitable visual encoder 410 similar to those described above with respect to the latent diffusion model of Figure 2. System 400 may be configured to generate a final latent representation by iteratively adding noise, and then denoising the final latent representation using a suitable AI model 415 such as U-Net, as described above with respect to Figures 2 and 3.
[0048] Similarly, system 400 also receives an input text prompt 420 (see Figure 4B) corresponding to text prompt 206. Medical image data 405 associated with a selected lesion may be accompanied by text information about the associated medical image. For example, the accompanying text information may be a radiology report or other medical report or record relating to the associated medical image data 405. Prompt 420 may be included in and / or extracted from this accompanying information. That is, text prompt 420 may be extracted from the text information associated with medical image data 405 using, for example, model 450 shown in Figure 4B or other natural language processing. This will be explained in more detail later.
[0049] The text prompt 420 is converted into a structured equivalent 455 using standard terminology from the vocabulary, as described later, tokenized, and used to generate an embedding 425. The embedding 425 is encoded into latent space using a text encoder 430, such as a CLIP encoder or another suitable text encoder. The latent representation of the embedding 425 is provided as input to the AI model 415.
[0050] As described above with respect to Figure 2, the cross-attention layer of the AI model 415 generates a cross-correlation map, such as a heatmap, between the text prompt 420 and the medical image data 405. This can be used in downstream applications such as phrase localization, annotation of medical image data using a heatmap or bounding box indicating the location of the text prompt 420 within the medical image data, and flagging medical image data for review or further action. This may optionally be provided on the display screen 26 or other output device, or simply stored in an optionally networked data storage unit for review by, for example, a medical professional. However, downstream applications are not limited to these, and the output heatmap or other localization information may be used in other applications that utilize localization in medical image data.
[0051] At least some embodiments provide technical improvements to computer-implemented medical image processing systems. In particular, these embodiments improve the operation of deep learning models that process medical image data and associated text data by modifying the way in which the model forms cross-modal spatial attention between image features and text features. The supervision described herein can reduce activation outside the target anatomical region and increase activation within or near the atlas-indicated anatomical region corresponding to the text data.
[0052] In at least some embodiments, the improved model output is an image-spatial output associated with medical image data. For example, the output may include a heatmap with spatial dimensions corresponding to the medical image, a bounding box superimposed on the medical image, a segmentation mask, annotation objects, or metadata identifying one or more localization candidate regions within the medical image. Such output may be displayed on a display device, stored in a medical image archive, or used as pseudo-labels for training another image processing model. Thus, the processing described herein improves technical image processing workflows not merely by automating mental processing or displaying medical text, but by improving the spatial alignment of model generation cross-attention activation with anatomical image regions.
[0053] Advantageously, the system 400 in Figure 4A is generated from atlas 460 (see Figure 4B) and can be substantially learned by adjusting or fine-tuning text prompt coding, e.g., 425 embeddings, by supervising cross-modal attention maps based on a synthetic heatmap based on a standard vocabulary of relevant anatomical structures.
[0054] As described above, the text prompt 420 may be entered (for example, as a result of manual or automated processing) or extracted from a medical report or record by NLP or other means. Rather than using the unstructured text prompt 420 as received, the text prompt 420 is converted into a structured equivalent 455 that is tailored to the lesion and anatomical location. The structure of the structured equivalent 455 of the text prompt 420 may include, but is not limited to, the location and lesion.
[0055] For example, the original prompt "faint peribronchial left upper lobe opacities" may be converted into a structured equivalent 455 having "left", "upper", and "pneumonia" as tokens, where "left" and "upper" are location terms and "pneumonia" is a lesion term. The structured equivalent 455 contains terms included in a pre-defined vocabulary.
[0056] Each structured equivalent 455 is associated with a coarse training signal that schematically represents a general anatomical region on the input image. This may be in the form of a distribution such as a Gaussian distribution, pseudo-Gaussian distribution, or similar function that can be substantially used as a composite heatmap 465. By using a Gaussian distribution, pseudo-Gaussian distribution, or similar function, a distribution is given to the training signal, allowing for a certain degree of freedom in localization while prioritizing fixation to a general anatomical region associated with the input prompt 420. The distribution / composite heatmap can be obtained using an atlas 460 that maps at least location terms from the vocabulary, and optionally other terms such as anatomical and / or pathological terms, to the relevant locations, distributions, and / or composite heatmaps.
[0057] Figure 4B shows an example of converting a text prompt 420 into a structured equivalent 455, which in turn converts it into a Gaussian or analogous function / composite heatmap 465.
[0058] In at least some embodiments, unstructured text prompts extracted from medical reports are converted into structured prompts containing one or more terms from a predetermined vocabulary. These structured prompts may include, for example, location terms and lesion terms. Location terms are mapped to a synthetic heatmap or other spatial distribution corresponding to areas of the medical image using a spatial landmark atlas. During training, one or more intermediate cross-attention maps generated by the deep learning model are compared to the synthetic heatmap. A loss function based on this comparison is used to update the model's text encoding, thereby improving spatial consistency between the structured prompts and the medical image. During inference, the trained model processes the medical image data and associated text data to generate localization information corresponding to the text data. This localization information may be output as an image spatial heatmap, bounding box, segmentation mask, annotation, or other spatial indication associated with the medical image data.
[0059] A trained model 450, such as RadGraph-XL or another BERT-type model, is implemented to extract clinical entities and their relationships, identifying at least positional modifiers within prompt 420. Prompt 420 is also searched for sentences in the accompanying material that refer to ground truth lesions. Optionally, a rule-based post-processing step may be applied to merge similar terms that refer to specific anatomical regions.
[0060] The search is enhanced by rules such as considering plural forms of each term and providing provisions for synonyms. For example, a radiologist may use the terms "opacity" or "consolidation" interchangeably with the term "pneumonia." Another rule that applies is to skip texts in which references to ground truth lesions appear with negative words such as "no," "without," or "absent," or with terms indicating resolution such as "resolved." Yet another applicable rule is to merge bilaterally symmetrical regions into a single term. For example, if both "left lower" and "right lower" exist, they may be represented by the single term "bilateral lower."
[0061] The method in Figure 4B uses a vocabulary. This vocabulary includes a set of candidate post-translation terms to which terms in the original prompt 420 can be mapped, such as location and / or lesion. Location may include general location terms such as "upper," "lower," "left," "right," and "bilateral," and / or location terms associated with specific anatomical structures or lesions, such as "lingular" (indicating the lower region of the left middle lobe of the lung), "cardiomegaly" (indicating the enlarged region of the heart), and "pulmonary" (referring to both lungs). This effectively provides a predefined list of possible post-translation terms, including location, lesion, and / or anatomical terms. Thus, the input phrase 420 may potentially contain any term, but the output of model 450 in this example will include terms included in the vocabulary. Any term identified by model 450 from prompt 420, such as location terms and / or anatomical or pathological terms, is labeled as an anatomical structure presence.
[0062] For anatomical locations specified in prompt text, converted terms extracted from model 450 can be mapped to spatial signals using atlas 460 in order to supervise the cross-attention activation of a pre-trained LDM (AI model 415, e.g., U-Net). For example, atlas 460 may include a lookup table (LUT) or other mapping mechanism, e.g., algorithm, AI model, etc., that maps location tokens (and optionally pathological and / or anatomical terms) from a vocabulary to a two-dimensional Gaussian distribution (or other suitable distribution) having predefined parameters μ and σ for forming a synthetic heatmap 465. The converted terms 455 extracted from prompt 420 by model 450 are matched with positional terms from at least the vocabulary within the atlas, and a Gaussian or other distribution associated with these terms is obtained, and a composite heatmap is provided.
[0063] Atlas 460, including LUTs or other mappings, may be derived from ground truth annotated images, such as medical images with annotated bounding boxes or other indications manually or otherwise added for specified locations. This may require additional mapping to map the terms used in the annotations of the annotated images to the post-converted terminology list. Bounding box locations within the annotated images may be used to indicate general anatomical regions associated with terms in the post-converted terminology list.
[0064] Since Model 415 expects images of a specific size, e.g., 512x512, as input, the ground truth bounding box from an annotated image can be scaled to the same resolution / scale. To provide weak supervision, the "ground truth" bounding box can have, for example, mean μ and variance σ. 2 It may be associated with a distribution such as a Gaussian distribution, a pseudo-Gaussian distribution, or a similar distribution.
[0065] To illustrate possible implementations, these may be determined using the following:
number
[0066] The variance may be set, for example, according to the 3σ rule of a Gaussian distribution. This means that approximately 99.7% of activations are within a specified minimum-maximum range, but this disclosure is not limited thereto. Bounding box statistics from ground truth annotated images can be averaged per anatomical location to design a lookup table (LUT) that maps at least terms (optionally including anatomical structure-based location terms and general location terms) to the mean and variance values of x and y as a function of input resolution. Optionally, these parameters may be perturbed at random rates to add randomness.
[0067] In this way, anatomical locations are substantially mapped as part of an atlas having the same dimensions as medical image data 405, for example, a heatmap / Gaussian distribution or other distribution. Each anatomical location is associated with its centroid and diameter, for example, corresponding to the mean and variance of the distribution.
[0068] During the training of the text encoder 430, the original text prompts 420 associated with specific medical image data 405 are converted into their structured equivalents 455. That is, the prompts 420 are converted during the training of the diffusion model. The token embeddings 425 are then fine-tuned so that cross-attention activation is restricted to or at least biased to the positions specified in the input prompts. This may include the use of a codebook with pre-trained embeddings, such as CLIP embeddings if the text encoder 430 is a CLIP encoder. The codebook has a size that depends on the total number of tokens, e.g., location terms, lesion terms and / or anatomical terms, special tokens, e.g., tokens used for joining, indicating start and end, etc., as well as the feature dimensions.
[0069] Following dediffusion processing, i.e., mapping the final latent representation / noise representation back to the latent representation of the medical image data 405, the resulting cross-activations, for example in the form of intermediate heatmaps, are extracted from multiple time steps / iterations. These may optionally include only selected iterations / time steps, such as intermediate iterations / time steps that do not include the initial and final iterations / steps. This yields a stack of cross-attention features.
[0070] Text prompt coding, e.g., embedding 425, is learned by supervising cross-modal attention using a loss term that includes at least a spatial loss term. Other parts of the model can be frozen. In the example, this may include a localization loss and optionally, in addition to or alternatively, a diversity loss term. The localization loss, and therefore the entire loss term, shows the correlation between the cross-activation / intermediate heatmap and the synthetic heatmap 465 obtained from atlas 460. Thus, to optimize the loss function, the parameters of text prompt coding, e.g., embedding 425, can be tuned.
[0071] In at least some embodiments, training adjusts only a portion of the model, leaving one or more other parts of the model frozen. For example, training may adjust token embeddings, text encoders, prompt encoders, or other text encoding parts of the model, while freezing image encoders, denoising networks, visual decoders, or one or more other image processing components. This allows for improvement of the spatial behavior of cross-attention activations without retraining the entire image generation or image processing model. In other embodiments, training may adjust one or more cross-attention layers, one or more projection layers that generate keys, queries, or values for cross-attention, one or more prompt embedding parameters, or a combination thereof. The parameters may be adjusted to optimize a loss function that includes a localization loss based on a synthetic heatmap derived from an atlas, and optionally a diversity loss to reduce overlap between token-level activations.
[0072] The diversity loss term is applied to cross-attention features normalized across feature dimension D to minimize overlap between token-level activations. An example of a diversity loss function may be as follows:
[0073]
number
[0074] Next, target signals used for supervision are dynamically extracted to force the cross-attention activations to exhibit desired spatial behavior. More specifically, the cross-attention activations are aggregated across the sequence dimension, excluding special tokens, using, for example, an average operator, a weighted average, or other weighted combinations, and then reshaped into a spatial feature map.
[0075]
number
[0076] Subsequently, given the aforementioned Gaussian distribution or other distribution target T∈R^D×D (reshaped to appropriate dimensions to match A_sp), the training signal can be defined as follows:
[0077]
number
[0078] On the other hand, the second term functions as a regularization term when the anatomical locations specified in the text do not undergo any cross-attention activation. In practice, α can be set to 0.1 or other appropriate value. The α term can account for the case where the true location lies outside the atlas-derived mask. In other words, the hyperplier α substantially controls how much weight is given to the weakly supervised signal / synthesized heatmap from the atlas and how much weight is given to the locations determined by the unsupervised model.
[0079] It has been found that performance improves by including the α hyperplier, i.e., its non-zero values, as shown in the table below. CNR is the contrast-to-noise ratio, which measures the statistical difference between the feature distribution inside and outside the bounding box, and mIoU is the average intersection over union, which measures the overlap between the ground truth bounding box region and the thresholded heatmap.
[0080] [Table 1]
[0081]
number
[0082] Advantageously, in the example, LDM can be learned using both anatomically supervised learning and learning by normal diffusion noise reduction, which have two simultaneous objectives. In the example, knowledge of lesions and their appearance may be incorporated into the atlas by adjusting for a Gaussian distribution such as the mean or standard deviation, or other distribution parameters, for each location.
[0083] In the method shown in Figure 4A, both the diversity loss 435 and the localization loss 440 are used. However, in other examples, only the localization loss 440 may be used, and the diversity loss 435 may not be used, or other appropriate loss functions may be used as an alternative or additional method. Furthermore, although a Gaussian distribution was described above, a quasi-Gaussian distribution or other appropriate distribution may be used. Also, although the mean of cross-attention activation is used, other combinations such as a weighted mean or other weighted combinations may be used.
[0084] When using system 400, during inference, the input text prompt 420 is converted to an embedding 425 based on supervised learning, including supervised learning that supervises a cross-modal attention map based on the atlas and vocabulary, as described above.
[0085] As described above, when in use, the output of the modified LDM, for example, a heatmap of the correlation between text prompts 206, 420 and medical images 204, 405, can be applied to downstream applications such as phrase localization, annotation of medical image data using a heatmap or bounding box indicating the location of the target medical image data of text prompt 420, flagging for review or further action of medical image data, and generating alerts. These may optionally be provided on the display screen 26 or other output device, or simply stored in an optionally networked data storage unit and made available for review, for example, by a medical professional.
[0086] The localization information generated by the system can assist clinicians or other users in reviewing medical imaging data. However, the system is not required to determine a final medical diagnosis, prognosis, treatment recommendation, or treatment decision. In at least some embodiments, the output may identify one or more candidate image regions corresponding to text data, and these candidate image regions may be reviewed by the clinician. For example, the system may output heatmaps, bounding boxes, segmentation masks, or highlighted regions corresponding to phrases in radiology reports or other medical records. Such output may be used to guide the review of medical images, to annotate medical images, to flag medical images for further review, or to generate training data for another image analysis model. Such output does not necessarily indicate the presence of disease and does not necessarily replace clinical interpretation by medical professionals.
[0087] In the example, the modified LDM described above, i.e., the LDM explained with respect to Figure 2, modified using the methods of Figures 4A and 4B, may be used to generate ground truth for supervised methods. This may take the form of a heatmap, segmentation, bounding box, etc., applied to the medical image data 405, for example.
[0088] The advantages of this method can be seen from the exemplary results shown in Figure 5. Figure 5 shows medical image data 405 of the morphology of a chest X-ray (CXR) image, the text prompt 420 "Faint peribronchial left upper lobe opacities", and the converted text prompt "left upper pneumonia" containing the tokens "left", "upper", and "pneumonia".
[0089] Figure 5 shows the intermediate heatmaps 505a-505c, 510a-510c, 515a-515c for each token obtained using (1) frozen LDM based on the original prompt, (2) frozen LDM based on the transformation prompt, and (3) the modified LDM of Figure 4A based on the transformation prompt, as well as the average heatmap 520a-520c for all tokens. The ground truth target location is indicated by the bounding box. From these, it is easy to see that the modified LDM based on the methods of Figures 4A and 4B, along with the transformation prompt 455, achieves the closest correlation with the target location for the average heatmap 520c.
[0090] Further evidence regarding the effectiveness of the methods in Figures 4A and 4B can be seen from the comparison results between this modified LDM method and specific benchmark techniques. These benchmark techniques include BioViL (Boecking et al., 2022), BioViL-T (Bannur et al., 2023), and the frozen LDM method outlined in Figure 2, i.e., the unsupervised method described in Figures 4A and 4B. For each benchmark technique and the modified LDM models to which the methods in Figures 4A and 4B are applied, the grounding results based on the MS-CXR-Loc dataset are shown in the table below, with the best index for each class highlighted in bold.
[0091] [Table 2]
[0092] From these findings, it can be seen that by applying the methods outlined in Figures 4A and 4B, performance against frozen LDM can be improved, and performance that is superior to or equivalent to benchmark methods can be achieved for many metrics.
[0093] Figure 6 shows cross-attention omissions in a pre-trained LDM. When a sentence extracted from a radiology report is used as the prompt 420 describing the input image (top path), cross-attention activation for interest tokens (left, upper, opacities) is diffused across the entire image region. Even when using a standardized structured prompt 455 following the format "" (middle path), activation does not clearly improve when used with frozen LDM. In contrast, as explained in Figures 4A and 4B, by combining a supervised learning-based fine-tuning method (bottom path), which involves training the embedding layer 425 using atlas-based supervised learning, with a pre-set vocabulary-based structured text prompt 455, more localized cross-attention activation can be obtained.
[0094] As illustrated in the example, atlas-supervised learning can reduce cross-attention leaks. Cross-attention leaks refer to the activation of cross-attention maps in image regions that do not correspond to anatomical locations or lesions indicated by relevant text tokens or structured prompt terms. By supervising one or more intermediate cross-attention maps with atlas-derived synthetic heatmaps, the model can be biased to generate higher activations in image regions corresponding to anatomical locations indicated by structured prompts and lower activations in irrelevant image regions. This reduction in cross-attention leaks can improve downstream image spatial localization outputs such as heatmaps, bounding boxes, segmentation masks, and annotations.
[0095] Furthermore, this improvement can reduce the need for manually annotated localized data when generating pseudo-labels for supervised medical image analysis models.
[0096] Figure 7 includes a flowchart of a computer implementation method based on the methods in Figures 4A and 4B. In step 705, an unstructured prompt 420 is extracted from a medical report or record relating to medical image data 405, for example using natural language processing (NLP). In step 710, the unstructured text prompt 420 is converted into a structured prompt 455 containing terms included in a pre-defined vocabulary. These terms include at least location terms and optionally anatomical terms and / or pathological terms, or both. This is done using an AI model such as the BERT model.
[0097] In step 715, the atlas 460 is used to map at least location terms from the structured prompt 455 to a composite heatmap or distribution showing the locations represented by the structured prompt 455, e.g., location terms. In step 720, a text stream for processing the text prompt 455, e.g., an embedding 425, is learned by supervised learning, which supervises intermediate heatmaps from the cross-attention layer of the AI model 415 with a loss function that shows the correlation between these heatmaps and the composite heatmaps from the atlas 460 mapped to the structured prompt 455.
[0098] In the usage step 725, which is a step shown by a dashed line as a step different from the learning step described above, an input pair including medical image data 405 and associated text prompts 420, for example, extracted from a medical report or record, is processed using LDM, which includes a visual encoder 410, a text encoder 430, and an AI model 415, a model 450 that converts unstructured prompts 420 to structured prompts 455, and a trained embedding 425, to localize the text prompts 420 of the input pair within the medical image data 405 of the input pair. The localization can be used downstream, as described above, for example, phrase localization, annotation of medical image data 405 for display or memory, highlighting lesions or anatomical structures represented in the medical image data, etc.
[0099] The method in Figure 7 may further include outputting localization information generated using a trained model. The localization information may be spatially aligned with medical image data and may include at least one of a heatmap, bounding box, segmentation mask, annotation, or highlighting region. The localization information may be displayed as an overlay on the medical image data, stored in association with the medical image data, or used as training data for another medical image analysis model. In some examples, the output does not involve determining a final medical diagnosis. Rather, the output may include identifying one or more candidate image regions corresponding to text data for use in clinician review or downstream image processing tasks.
[0100] Some aspects and optional features of this method are outlined below. In some embodiments, one or more intermediate heatmaps are extracted from multiple cross-attention layers and multiple diffusion timesteps. The extracted heatmaps may be normalized, resized to a spatial resolution corresponding to medical image data, and aggregated across one or more layers, timesteps, or tokens.
[0101] In some embodiments, the composite heatmap is generated from a spatial distribution associated with anatomical locations within the atlas. The spatial distribution may include a Gaussian distribution, a pseudo-Gaussian distribution, a quasi-Gaussian distribution, a binary mask, or other spatial weighting function. The parameters of the spatial distribution may be derived from annotated medical images or adjusted based on lesion type, anatomical location, image modality, or input image resolution.
[0102] In some embodiments, training the model involves minimizing a loss function that includes a localization loss that penalizes deviations between one or more intermediate heatmaps and a composite heatmap. The loss function may further include a diversity loss that reduces overlap between activations corresponding to different text tokens. In some embodiments, weighting parameters control the relative contributions of atlas-derived supervision and attention activations generated by the model.
[0103] In some embodiments, a trained model is used to generate pseudo-ground truth localized data for another model. The pseudo-ground truth localized data may include heatmaps, segmentation masks, bounding boxes, point annotations, or other spatial labels associated with medical image data.
[0104] In a first embodiment, a medical image processing method is provided for improving latent representations extracted from diffusion models. Supervised learning of a cross-attention layer can be used to ensure better matching between text tokens and correct anatomical image locations. Training signals extracted from a combination of NLP and spatial landmark atlases from radiology reports may be used. This method may be used to train any deep learning representation, including spatial attention, not limited to diffusion model representations. Average heatmaps, optionally weighted average heatmaps, may be used not only for downstream tasks but also for training.
[0105] Knowledge of lesions and their appearance may be incorporated into the atlas by adjusting Gaussian or other parameters, such as mean and standard deviation, for each location. The network may be trained using two or more simultaneous objectives, such as anatomical supervision and standard diffusion denoising. Prompts may be transformed during the training of the diffusion model. The fine-tuned LDM or other model may be used to generate ground truth for supervised methods, for example, in the form of heatmaps, segmentation, or bounding boxes.
[0106] In a further embodiment, a method for training a model is provided, which includes training the model's cross-attention layer based on at least a spatial loss term. Training may include training based on diversity loss. Training may include training based on both diversity loss and spatial loss. The spatial loss term may be represented by a spatial loss function. The spatial loss function may include a Gaussian distribution, a quasi-Gaussian distribution, a binary mask, or any other desired or selected distribution. Training may also be based on localization loss, and / or the spatial loss term may include localization loss. Different spatial loss functions may be used for different anatomical features or locations and / or different lesions.
[0107] The cross-attention layer may represent cross-modal attention, for example, spatial attention in an image determined based on text. Model training may include training a text prompt encoder. Training may include supervising a cross-modal attention map to match a synthetic heatmap generated from an atlas. The cross-modal attention map may include the output of the cross-attention layer. The method may include providing a structured vocabulary representing lesions and / or anatomical locations or features. The method may include mapping lesions and / or anatomical locations or features to an atlas. The method may include receiving text input, for example, text prompts, transforming the text input using the structured vocabulary, for example, to generate structured text input. The method may include training a cross-attention layer using the structured text input. Text items included in the structured vocabulary may have, for example, relevant anatomical locations represented in an atlas. Text input may include patient records or parts thereof, and / or radiology reports. This method may include incorporating knowledge of lesions and / or their appearance into the atlas by, for example, adjusting the parameters of the loss function, such as the mean and standard deviation, to be location-dependent, for example, different for different locations. The model may be trained for two or more simultaneous purposes; for example, the model may be trained based on anatomical supervision and diffusion denoising purposes. Alternatively, the model may be trained sequentially using two or more purposes in sequence. At least some model features may be frozen after training based on one of the set of purposes. The model may be used to generate one or more heatmaps, segmentations, or bounding boxes. The cross-attention layer may be trained to provide alignment between text tokens and correct anatomical image locations. Supervised training may include using text extracted from radiology reports by a combination of NLP and spatial landmark atlases. The model may include latent diffusion models. The model may include any suitable model that includes spatial attention representations.
[0108] Another embodiment includes a medical image processing method. This method includes configuring a deep learning model that includes one or more cross-attention layers between text data and medical image data. The text data relates to pathological or anatomical features to be correlated with the location of pathological or anatomical features in the medical image data. This method includes supervised learning of one or more cross-attention layers, the supervised learning including one or both of the following: a teacher signal extracted from a medical report or record associated with the medical image data, and / or a teacher signal using a spatial landmark atlas.
[0109] Another embodiment includes a method for processing medical image data. This method includes applying medical image data and text prompts to a deep learning model. The text prompts include text data relating to pathological or anatomical features that should be correlated with the location of pathological or anatomical features in the medical image data.
[0110] The deep learning model includes one or more cross-attention layers between text data and medical image data, and the one or more cross-attention layers are trained by supervised learning that includes either or both of the following: training signals extracted from medical reports or records associated with the medical image data, and / or training signals using a spatial landmark atlas. Optionally, the method may include localizing pathological or anatomical features contained in text prompts within medical image data and outputting the localization of pathological or anatomical features contained in text prompts within medical image data to a display device or other output device, or to a computer-readable data storage unit. The localization of text prompts may include localizing anatomical features represented in medical image data with respect to the text prompts.
[0111] Another embodiment includes a system comprising at least one processor and memory. The system is configured to constitute a deep learning model comprising one or more cross-attention layers between text data and medical image data. The text data relates to pathological or anatomical features to be correlated with the location of pathological or anatomical features in medical image data. The configuration of the deep learning model comprises supervised learning of one or more cross-attention layers, the supervised learning comprising either or both of the following: a teacher signal extracted from a medical report or record associated with the medical image data, and / or a teacher signal using a spatial landmark atlas. Optionally, the system may include or be configured to communicate with a display device and / or other output devices, and to apply the deep learning model to localize pathological or anatomical features contained in text prompts within medical image data, and to output the localization of pathological or anatomical features contained in text prompts within medical image data to the display device or other output device, or to a computer-readable data storage unit.
[0112] Features in one aspect or embodiment can be combined with features in any other aspect or embodiment in any suitable combination. For example, apparatus features may be provided as method features, and vice versa.
[0113] In some embodiments, the scanner 24 includes an X-ray imaging device. The X-ray imaging device may include an X-ray tube configured to generate X-rays and an X-ray detector configured to detect X-rays generated by the X-ray tube and passing through a subject. A processing circuit of the X-ray imaging device, or a processing circuit communicably coupled to the X-ray imaging device, may be configured to generate X-ray image data based on the output of the X-ray detector. The processing circuit may acquire text data associated with the X-ray image data and be configured to process the X-ray image data and text data using a deep learning model including one or more cross-attention layers. The deep learning model may be configured to generate localization information indicating regions of the X-ray image data corresponding to the text data. The localization information may include a heatmap, bounding box, segmentation mask, annotation, enhanced region, or other image space output spatially aligned with the X-ray image data.
[0114] In some embodiments, the deep learning model is trained by supervised learning, which includes training one or more cross-attention layers using either or both of the terminology and / or spatial landmark atlases contained in the vocabulary. For example, terminology derived from text data may be mapped by the spatial landmark atlas to a synthetic heatmap representing anatomical locations in X-ray image data, and one or more intermediate heatmaps extracted from one or more cross-attention layers may be trained based on the synthetic heatmap. The localization information may be displayed as an overlay on the X-ray image data, stored in association with the X-ray image data, or used as pseudo-label data for training another medical image processing model. The localization information may identify one or more candidate image regions for clinician review and does not need to determine a final medical diagnosis.
[0115] While specific circuits have been described herein, in alternative embodiments, one or more functions of these circuits may be provided by a single processing resource or other components, or functions provided by a single circuit may be provided by a combination of two or more processing resources or other components. A reference to a single circuit encompasses multiple components that provide the functions of that circuit, regardless of whether such components are spatially separated. Similarly, a reference to multiple circuits encompasses a single component that provides the functions of those circuits.
[0116] While specific embodiments have been described, these embodiments are presented only as examples and are not intended to limit the scope of the invention. In fact, the novel methods and systems described herein can be embodied in various other forms. Furthermore, various omissions, substitutions, and modifications can be made in the forms of methods and systems described herein without departing from the spirit of the invention. The appended claims and their equivalents are intended to encompass such forms and modifications that fall within the scope of the invention. [Explanation of Symbols]
[0117] 20...Data processing unit, 22...Calculation unit, 24...Scanner, 26...Display screen, 28...Input device, 30...Data storage unit, 32...Processing unit, 34, 36, 38...Circuits, 34...Image processor, 36...Prompt processor, 38...Interface circuit, 40...Data processing circuit
Claims
1. A deep learning model is constructed that includes one or more cross-attention layers to localize text data to medical image data. A medical image processing method comprising performing supervised learning, which includes supervising one or more cross-attention layers using either or both of the terms derived from the text data and included in the vocabulary, and a spatial landmark atlas.
2. The medical image processing method according to claim 1, wherein the text data is extracted from a medical report or record associated with the medical image data.
3. The medical image processing method according to claim 1, wherein the spatial landmark atlas includes a plurality of composite heatmaps or location distributions associated with terms included in the vocabulary.
4. The medical image processing method according to claim 3, wherein the composite heatmap includes, or is generated from, a Gaussian distribution, a pseudo-Gaussian distribution, or other distribution associated with terms derived from a medical report or record.
5. The medical image processing method according to claim 3, comprising selecting one or more composite heatmaps from the atlas that are associated with terms contained in the vocabulary derived from the text data.
6. The medical image processing method according to claim 5, wherein the terms derived from the text data include positional terms indicating location, and the selected composite heatmap indicates the location indicated by the terms derived from the text data.
7. The medical image processing method according to claim 3, wherein the terms associated with the composite heatmap or location distribution in the atlas are derived by applying natural language processing to a medical report or record.
8. This includes determining one or more intermediate heatmaps derived from one or more of the aforementioned cross-attention layers. Each intermediate heatmap shows the degree of correlation between the text data and the medical image data. The supervision includes applying a spatial loss function that at least partially indicates the degree of deviation of one or more intermediate heatmaps from the composite heatmap. The medical image processing method according to claim 1.
9. The medical image processing method according to claim 8, wherein the supervision includes supervising the mean, weighted mean, or other combination of the intermediate heatmap.
10. The medical image processing method according to claim 9, wherein the average, weighted average, or other combination of the heatmap is also used for downstream tasks.
11. The medical image processing method according to claim 3, wherein knowledge and appearance of lesions are incorporated into the atlas by adjusting Gaussian parameters for each location.
12. The medical image processing method according to claim 1, wherein the deep learning model includes a latent diffusion model or another diffusion model.
13. The deep learning model is trained for at least two simultaneous objectives. At least one of the aforementioned objectives includes learning by anatomical guidance, At least one of the aforementioned objectives includes the purpose of diffusion denoising. The medical image processing method according to claim 1.
14. The medical image processing method according to claim 1, wherein the text data is converted during the training of the deep learning model.
15. The medical image processing method according to claim 1, wherein the deep learning model is used to generate ground truth for a supervised method in the form of a heatmap, segmentation, or bounding box.
16. Applying medical image data and text data to a deep learning model, This includes localizing the text data with respect to the medical image data, The deep learning model includes one or more cross-attention layers for determining the correlation between the text data and the medical image data. The deep learning model is trained by supervised learning, which includes mapping terms derived from the text data and included in the vocabulary to a synthetic heatmap or location distribution using a spatial landmark atlas, and supervising one or more intermediate heatmaps derived from one or more cross-attention layers based on the synthetic heatmap or location distribution. Medical image processing methods.
17. The medical image processing method according to claim 16, further comprising outputting the localization of the text data with respect to the medical image data onto a display device or other output device, or into a computer-readable data storage unit.
18. A medical image processing apparatus comprising at least one processor and memory, The medical image processing device is configured to implement a deep learning model that includes one or more cross-attention layers for localizing text data with respect to medical image data. The deep learning model is trained by supervised learning, which includes mapping terms derived from the text data and included in the vocabulary to a synthetic heatmap or location distribution using a spatial landmark atlas, and supervising one or more intermediate heatmaps derived from one or more cross-attention layers based on the synthetic heatmap or location distribution. Medical image processing equipment.
19. It is equipped with a display device and / or other output device, or configured to communicate with the said display device and / or other output device, The localization of the text data and the medical image data is configured to be output on the display device or other output device, or into a computer-readable data storage unit. The medical image processing apparatus according to claim 18.
20. An X-ray tube configured to generate X-rays, An X-ray detector configured to detect X-rays generated by the aforementioned X-ray tube and passing through a subject, A processing circuit configured to generate X-ray image data based on the output of the X-ray detector and to implement a deep learning model that includes one or more cross-attention layers for localizing text data to the X-ray image data, Equipped with, The deep learning model is trained by supervised learning, which includes supervising one or more cross-attention layers using either or both of the terms and spatial landmark atlas contained in the vocabulary. X-ray imaging device.
Citation Information
Patent Citations
Text-based Realistic Image Editing Using Diffusion Models
JP7691548B2
