Ultrasonic navigation action determination method and device

By training discrete self-coding pre-training models and building hidden space generation models, the problem of low efficiency and accuracy of existing ultrasound autonomous navigation methods is solved, and efficient and accurate ultrasound examination and image quality improvement are achieved to adapt to individual needs of different signs. .

CN119273640AInactive Publication Date: 2025-01-07BEIJING LINGSHI ZHIYUAN TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411309111.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-19
Publication Date
2025-01-07
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

The existing ultrasonic autonomous navigation methods have low execution efficiency and accuracy, making it difficult to adapt to individuals with different signs, and the quality of ultrasonic images depends on the operator's technology and experience, resulting in limited inspection efficiency and accuracy.

Method used

By using historical ultrasound images to train discrete self-encoding pre-trained models, build hidden space generation model and ultrasound image quality evaluation model, the ultrasound navigation model is trained to achieve end-to-end adaptive ultrasound navigation, and improve ultrasound examination efficiency and image quality.

Benefits of technology

The efficiency and image quality of ultrasound examination are significantly improved, adaptability to individuals with different signs is achieved, and decision-making accuracy and generalization ability of the ultrasound navigation model are enhanced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119273640A_ABST
    Figure CN119273640A_ABST
Patent Text Reader

Abstract

The invention provides an ultrasonic navigation action determination method and device, and relates to the technical field of ultrasonic navigation, and the method comprises the steps: training a discrete self-coding pre-training model by using a historical ultrasonic image, extracting discrete features from an input ultrasonic image, and carrying out image reconstruction based on the discrete features; a hidden space generation model is constructed and used for generating an ultrasonic image of a corresponding position after the ultrasonic navigation action is executed at the current position according to the input ultrasonic image of the current position and the ultrasonic navigation action; constructing an ultrasonic image quality evaluation model for outputting a quality evaluation result of the ultrasonic image according to the input ultrasonic image; training by using the hidden space generation model and the ultrasonic image quality evaluation model to obtain an ultrasonic navigation model; and inputting a current ultrasonic image obtained by ultrasonic treatment at the current moment into the ultrasonic navigation model to obtain a target ultrasonic navigation action.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of ultrasonic navigation technology, and in particular to an ultrasonic navigation action determination method and device. Background Art

[0002] Ultrasound is a non-invasive examination method that uses ultrasound (high-frequency sound waves) to provide detailed images and dynamic activity information of the examination target (such as the heart). It is a widely used diagnostic tool in clinical practice and has important clinical value and significance. Ultrasound autonomous navigation tasks are a novel research direction in the field of embodied intelligence, which realizes automated ultrasound examinations by integrating artificial intelligence, robotics and medical imaging.

[0003] However, the execution efficiency and accuracy of some existing ultrasound autonomous navigation methods are relatively poor, and it is difficult to adapt to individuals with different physical signs. Therefore, it is urgent to propose an ultrasound navigation action determination method and device to improve the quality of ultrasound images obtained in ultrasound autonomous navigation tasks. Summary of the invention

[0004] In view of the above problems, the embodiments of the present application provide an ultrasound navigation action determination method and device to overcome the above problems or at least partially solve the above problems.

[0005] In a first aspect of an embodiment of the present application, a method for determining an ultrasound navigation action is provided, the method comprising: Using historical ultrasound images, training a discrete autoencoder pre-training model, wherein the discrete autoencoder pre-training model is used to extract discrete features from an input ultrasound image and perform image reconstruction based on the discrete features; Based on the discrete autoencoder pre-training model, a latent space generation model is constructed, wherein the latent space generation model is used to generate an ultrasound image at a corresponding position after the ultrasound navigation action is performed at the current position according to the input ultrasound image at the current position and the ultrasound navigation action; Based on the discrete autoencoder pre-training model, an ultrasound image quality evaluation model is constructed, wherein the ultrasound image quality evaluation model is used to output a quality evaluation result of the ultrasound image according to an input ultrasound image; Using the latent space generation model and the ultrasound image quality evaluation model, an ultrasound navigation model is trained; The current ultrasound image obtained by performing ultrasound at the current moment is input into the ultrasound navigation model to obtain a target ultrasound navigation action, and the target ultrasound navigation action is used to indicate the movement action that the ultrasound probe needs to perform at the next moment.

[0006] In a possible implementation, the ultrasound navigation model includes an encoder, and the encoder of the ultrasound navigation model is the first encoder in the discrete autoencoder pre-training model; and the ultrasound navigation model is obtained by training using the latent space generation model and the ultrasound image quality evaluation model, including: Acquire the current ultrasound sample image and the historical ultrasound sample images to generate an ultrasound sample image sequence at the current moment; Inputting the ultrasound sample image sequence at the current moment into the ultrasound navigation model to obtain a predicted action; Inputting the predicted action and the current ultrasound sample image into the latent space generation model to obtain a predicted ultrasound image at the next position; Inputting the predicted ultrasound image into the ultrasound image quality evaluation model to obtain a quality evaluation result of the predicted ultrasound image; Calculating a reward function according to a quality evaluation result of the predicted ultrasound image, and optimizing parameters of the ultrasound navigation model according to the calculation result of the reward function; Determine whether a preset end condition is met, and if the preset end condition is not met, add the current ultrasound sample image to the historical ultrasound sample image, use the predicted ultrasound image at the next position as the current ultrasound sample image input into the ultrasound navigation model at the next moment, and repeat the above steps until the preset end condition is met; Acquire new current ultrasound sample images and historical ultrasound sample images, and repeat the above steps until a preset number of training times is reached, then terminate the training and obtain a trained ultrasound navigation model.

[0007] In a possible implementation manner, the sequence length of the ultrasound sample image sequence at the next moment is one unit greater than the sequence length of the ultrasound sample image sequence at the current moment; and the preset end condition includes at least one of the following: The calculation result of the reward function reaches a preset standard; The sequence length of the ultrasound sample image sequence at the current moment reaches a maximum value.

[0008] In a possible implementation, the calculation formula of the reward function is as follows: ; in, is the current ultrasound sample image at the tth moment, is the current ultrasound sample image at the tth moment output by the ultrasound image quality assessment model The quality evaluation results of is the current ultrasound sample image at time t-1, is the current ultrasound sample image at the t-1th moment output by the ultrasound image quality assessment model The quality evaluation results of is a fixed coefficient, Indicates whether to stop the current round of training after the tth moment.

[0009] In a possible implementation, the use of historical ultrasound images to train a discrete autoencoder pre-training model includes: Inputting the historical ultrasound image into a first encoder of the discrete autoencoder pre-training model to obtain an encoded feature map; Inputting the encoded feature map into the dimension reduction convolution module of the discrete autoencoder pre-training model to obtain the feature map after dimension reduction convolution; Perform nearest neighbor query and replacement on the feature map after the dimensionality reduction convolution and the features in the code table of the discrete autoencoder pre-training model to obtain multiple feature indexes; each feature index corresponds to a feature in the code table; According to the multiple feature indexes, sampling is performed in the code table to obtain a discretized feature map; Inputting the sampled feature map into the dimension-increasing convolution module of the discrete autoencoder pre-training model to obtain the feature map after dimension-increasing convolution; Using the first decoder of the discrete autoencoder pre-training model, restoring the features of the feature map after the dimension-raising convolution, to obtain a reconstructed ultrasound image; Calculating a first loss function value according to the historical ultrasound image and the reconstructed ultrasound image, and updating parameters of the discrete autoencoder pre-training model according to the first loss function value; Repeat the above steps until the first loss function value converges or reaches a preset number of training times, and then terminate the training to obtain a discrete autoencoder pre-training model that has been trained.

[0010] In a possible implementation, the first loss function value is calculated according to the historical ultrasound image and the reconstructed ultrasound image according to the following formula: ; Wherein, x represents the historical ultrasound image, represents the discretized feature map, represents the mean square error loss between the reconstructed ultrasound image and the historical ultrasound image, represents the encoded feature map, e represents the feature in the code table, sg represents not calculating the gradient, is the loss coefficient.

[0011] In a possible implementation, constructing a latent space generation model based on the discrete autoencoder pre-training model includes: Inputting the first ultrasound image into the discrete encoder of the latent space generation model, extracting discrete features, and obtaining the first discrete features through the embedding layer of the latent space generation model; the discrete encoder of the latent space generation model is composed of the first encoder of the discrete autoencoder pre-training model that has been trained, the dimensionality reduction convolution module and the code table; The second ultrasonic image is input into the discrete encoder, and after the discrete features are extracted, the second discrete features are obtained by the embedding layer of the latent space generation model; the second ultrasonic image is an image obtained by performing an ultrasonic operation at the ultrasonic position corresponding to the first ultrasonic image after the first ultrasonic navigation action is performed; After splicing the first discrete feature and the first ultrasound navigation action by using the splicing module of the latent space generation model, an encoding result is obtained by using the encoding module of the latent space generation model; Decoding the encoding result and the second discrete feature by using a decoding module of the latent space generation model, and obtaining a discrete encoding result through a linear layer; Inputting the discrete coding result into the discrete decoder of the latent space generation model to obtain a predicted ultrasound image for the first ultrasound navigation action; the discrete decoder is composed of the dimension-raising convolution module of the trained discrete autoencoder pre-training model, the first decoder and the code table; Calculating a second loss function value according to the second ultrasound image and the predicted ultrasound image for the first ultrasound navigation action; According to the second loss function value, on the basis of freezing the discrete encoder and the discrete decoder, updating the parameters of the latent space generation model; Repeat the above steps until the second loss function value converges or reaches a preset number of training times, then end the training to obtain a trained latent space generation model.

[0012] In a possible implementation, constructing an ultrasound image quality assessment model based on the discrete autoencoder pre-training model includes: Inputting the third ultrasound image into the encoder of the ultrasound image quality assessment model to obtain an encoded feature map, wherein the encoder of the ultrasound image quality assessment model is composed of the first encoder of the discrete autoencoder pre-trained model that has been trained; The encoded feature map is passed through a residual unit and a global pooling layer of the ultrasound image quality assessment model to obtain a pooling result; Inputting the onehot representation of the third ultrasonic image into the linear layer of the ultrasonic image quality assessment model to obtain a first processing result; Obtaining a quality evaluation result of the third ultrasound image according to the first processing result and the pooling result; Calculating a third loss function value according to a quality evaluation result of the third ultrasonic image; On the basis of freezing the encoder of the ultrasound image quality assessment model, updating parameters according to the third loss function value; The above steps are repeated until the third loss function value converges or reaches a preset number of training times, and the training is terminated to obtain a trained ultrasound image quality evaluation model.

[0013] In a possible implementation, the ultrasound navigation action includes at least one of the following: Translate 3 mm along the positive direction of the x-axis; Translate 3 mm along the negative direction of the x-axis; Translate 3 mm along the positive direction of the y-axis; Translate 3 mm along the negative direction of the y axis; Translate 3 mm along the positive direction of the z-axis; Translate 3 mm along the negative direction of the z-axis; Rotate 5 degrees along the positive direction of the x-axis; Rotate 5 degrees along the negative direction of the x-axis; Rotate 5 degrees along the positive direction of the y axis; Rotate 5 degrees along the negative direction of the y axis; Rotate 5 degrees along the positive direction of the z axis; Rotate 5 degrees along the negative direction of the z axis; Stop the action.

[0014] The second aspect of the embodiment of the present application further provides an ultrasound navigation action determination device, which is used to execute the ultrasound navigation action determination method described in the first aspect of the embodiment of the present application, and the device includes: A first construction module is used to train a discrete autoencoder pre-training model using historical ultrasound images, wherein the discrete autoencoder pre-training model is used to extract discrete features from an input ultrasound image and perform image reconstruction based on the discrete features; A second construction module is used to construct a latent space generation model based on the discrete autoencoder pre-training model, wherein the latent space generation model is used to generate an ultrasound image at a corresponding position after the ultrasound navigation action is performed at the current position according to the input ultrasound image at the current position and the ultrasound navigation action; A third construction module is used to construct an ultrasound image quality evaluation model based on the discrete autoencoder pre-training model, and the ultrasound image quality evaluation model is used to output a quality evaluation result of the ultrasound image according to an input ultrasound image; A fourth construction module is used to train an ultrasound navigation model using the latent space generation model and the ultrasound image quality evaluation model; The ultrasound navigation action determination module is used to input the current ultrasound image obtained by ultrasound at the current moment into the ultrasound navigation model to obtain a target ultrasound navigation action, and the target ultrasound navigation action is used to indicate the movement action that the ultrasound probe needs to perform at the next moment.

[0015] The third aspect of the embodiments of the present application also provides an electronic device, including a memory, a processor and a computer program stored on the memory, and the processor executes the computer program to implement the steps in the ultrasound navigation action determination method described in the first aspect of the embodiments of the present application.

[0016] The fourth aspect of the embodiments of the present application further provides a computer-readable storage medium on which a computer program / instruction is stored. When the computer program / instruction is executed by a processor, the steps in the ultrasound navigation action determination method described in the first aspect of the embodiments of the present application are implemented.

[0017] The fifth aspect of the embodiments of the present application further provides a computer program product. When the computer program product is run on an electronic device, the processor implements the steps in the ultrasound navigation action determination method as described in the first aspect of the embodiments of the present application.

[0018] An embodiment of the present application provides a method for determining an ultrasound navigation action, the method comprising: using historical ultrasound images to train a discrete autoencoder pre-training model, the discrete autoencoder pre-training model is used to extract discrete features from an input ultrasound image, and reconstruct an image based on the discrete features; based on the discrete autoencoder pre-training model, a latent space generation model is constructed, the latent space generation model is used to generate an ultrasound image at a corresponding position after the ultrasound navigation action is performed at the current position according to the input ultrasound image at the current position and the ultrasound navigation action; based on the discrete autoencoder pre-training model, an ultrasound image quality evaluation model is constructed, the ultrasound image quality evaluation model is used to output a quality evaluation result of the ultrasound image according to the input ultrasound image; using the latent space generation model and the ultrasound image quality evaluation model to train an ultrasound navigation model; and inputting a current ultrasound image obtained by ultrasound at the current moment into the ultrasound navigation model to obtain a target ultrasound navigation action, the target ultrasound navigation action being used to indicate the movement action that the ultrasound probe needs to perform at the next moment.

[0019] The embodiment of the present application proposes a method for determining ultrasound navigation actions, which improves the decision accuracy of the ultrasound navigation model (i.e., the accuracy of the output ultrasound navigation actions) by constructing a latent space generation model and an ultrasound image quality evaluation model. In actual application, the method only relies on the trained ultrasound navigation model for real-time decision making. On the one hand, the method realizes end-to-end adaptive ultrasound navigation and significantly improves the efficiency of ultrasound examination; on the other hand, the method uses a self-supervised method to train the ultrasound navigation model, which has strong generalization to adapt to individuals with different physical signs and further improve the quality of ultrasound images. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the description of the embodiments of the present application will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0021] Figure 1 is a flowchart of a method for determining an ultrasound navigation action provided in an embodiment of the present application; Figure 2 It is a structural schematic diagram of a discrete autoencoder pre-training model provided in an embodiment of the present application; Figure 3 It is a schematic diagram of a training process of a latent space generation model provided in an embodiment of the present application; Figure 4 is a schematic diagram of a training process of an ultrasound image quality assessment model provided in an embodiment of the present application; Figure 5 is a schematic diagram of a training process of an ultrasound navigation model provided in an embodiment of the present application; Figure 6 is a structural schematic diagram of an ultrasonic navigation action determination device provided in an embodiment of the present application; Figure 7 It is a schematic diagram of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0022] The exemplary embodiments of the present application will be described in more detail below in conjunction with the accompanying drawings in the embodiments of the present application. Although the exemplary embodiments of the present application are shown in the accompanying drawings, it should be understood that the present application can be implemented in various forms and should not be limited by the embodiments set forth herein. On the contrary, these embodiments are provided in order to enable a more thorough understanding of the present application and to enable the scope of the present application to be fully communicated to those skilled in the art.

[0023] Ultrasound is a non-invasive examination method that uses ultrasound (high-frequency sound waves) to evaluate the structure and function of the object of examination (such as the heart). It is a widely used diagnostic tool in clinical practice, which can provide detailed images and dynamic activity information of the object of examination (such as the heart). It has important value and significance in clinical practice. Among them, cardiac ultrasound is the most widely used. As a non-invasive and radiation-free imaging technology, cardiac ultrasound technology can provide real-time information on the structure and function of the heart, allowing doctors to quickly and accurately diagnose various heart diseases, such as coronary heart disease, cardiomyopathy, valvular heart disease and congenital heart disease, and adjust treatment plans accordingly.

[0024] Although ultrasound has many advantages, it is currently facing some bottlenecks in the industry. First, the quality of ultrasound images and diagnostic accuracy are highly dependent on the skills and experience of ultrasound operators. Ultrasound operators need to find the ultrasound imaging window of the object of examination (such as the heart) to scan the corresponding section. Due to the innate body shape of different subjects, the observation window position of the section is not fixed, and different operators have different definitions of section standards, which poses a challenge to the downward popularization and standardization of ultrasound. Secondly, the training speed of ultrasound operators cannot meet the growing clinical needs. Ultrasound examination requires highly professional skills and rich experience, and it usually takes several years to train a qualified ultrasound operator. With the increase in the incidence of diseases, the demand for ultrasound examinations in clinical practice continues to rise, but the supply of ultrasound operators has been difficult to keep up, resulting in longer waiting times for ultrasound examinations and delayed diagnosis and treatment. Therefore, how to quickly popularize and standardize the process of ultrasound examinations and fill the current shortage of ultrasound operators has become a key issue that needs to be urgently solved in the ultrasound industry.

[0025] Ultrasound autonomous navigation is a novel research direction in the field of embodied intelligence. It realizes automated ultrasound examination by integrating artificial intelligence, robotics and medical imaging. However, the efficiency and accuracy of some current ultrasound autonomous scanning methods are relatively poor. Specifically, the ultrasound autonomous navigation system uses deep learning algorithms to analyze ultrasound images in real time and autonomously adjusts the position and angle of the ultrasound probe by controlling the robotic arm to obtain the best imaging perspective. Most methods use image classification and segmentation methods to extract the key features of ultrasound images, and perform manually preset actions based on the current features to achieve the purpose of autonomous scanning. However, the above methods are inefficient and need to obtain features first and then map the corresponding actions. They cannot be executed end-to-end, and ultrasound imaging is a dynamically changing process. It is difficult to exhaust the mapping relationship between features and actions. In addition to the above methods, some end-to-end methods use ultrasound images as input and use strong supervision to let the model directly output the corresponding actions. Although this can significantly improve the inspection efficiency, the strong supervision method makes the deep model poorly generalized and difficult to adapt to individuals with different signs.

[0026] In view of the above problems, the present application proposes an ultrasound navigation action determination method to improve the quality of ultrasound images. In conjunction with the accompanying drawings, the following describes in detail a single target direction vector multi-aperture joint solution method provided by the present application through some embodiments and their application scenarios.

[0027] The first aspect of the present application provides a method for determining an ultrasound navigation action, referring to Figure 1 , Figure 1 A flowchart of a method for determining an ultrasound navigation action provided in an embodiment of the present application is shown in FIG. Figure 1 As shown, the method includes: Step S101, using historical ultrasound images to train a discrete autoencoder pre-training model, the discrete autoencoder pre-training model is used to extract discrete features from an input ultrasound image and perform image reconstruction based on the discrete features.

[0028] Reference Figure 2 , Figure 2 A schematic diagram of the structure of a discrete autoencoder pre-training model is shown, such as Figure 2 As shown, the discrete autoencoder pre-training model is used to extract discrete features from an input ultrasound image and reconstruct the image based on the discrete features. Specifically, the discrete autoencoder pre-training model includes: a first encoder (corresponding to Figure 2 The encoder in ), the dimension reduction convolution module, the code table, the dimension increase convolution module and the first decoder (corresponding to Figure 2 The first encoder and the first decoder are mainly composed of convolutional layers, activation functions and layer normalization modules, and the code table is mainly composed of linear layers. The number of code tables is 128 and the dimension is 4, including multiple code table features (such as Figure 2 The e1, e2, ..., e shown n ), each code table feature corresponds to a feature index in the form of an integer, so that the corresponding code table feature can be obtained from the code table according to the feature index. The discrete autoencoder pre-trained model can abstract the input ultrasound image into 28×28 numbers (i.e., discrete features) for representation through the first encoder and the code table, and can use the first decoder to restore the discrete features to the original image to achieve image reconstruction.

[0029] In addition, the ultrasound images used (including the historical ultrasound images, the first ultrasound images, the second ultrasound images, and the third ultrasound images mentioned later) need to be consistent with the type of the inspection object in the actual application scenario. For example, if the application scenario is for cardiac ultrasound (i.e., the inspection object is the heart), the discrete autoencoder pre-training model, latent space generation model, ultrasound image quality evaluation model, and ultrasound navigation model established are all models constructed for cardiac ultrasound, and the ultrasound images used in the model training process (including the historical ultrasound images, the first ultrasound images, the second ultrasound images, and the third ultrasound images mentioned later) are all ultrasound images of the heart, and cannot be ultrasound images of other parts.

[0030] In a possible implementation, the step S101, using historical ultrasound images to train a discrete autoencoder pre-training model, includes: Step S1011, input the historical ultrasound image into the first encoder of the discrete autoencoder pre-training model to obtain an encoded feature map. Specifically, the discrete autoencoder pre-training model is trained using the historical ultrasound image as training data, and the input historical ultrasound image (which can be a three-channel color image with a size of 224×224×3) is encoded by the first encoder to extract the encoded feature map (with a dimension of 28×28×128).

[0031] Step S1012, input the encoded feature map into the dimensionality reduction convolution module of the discrete autoencoder pre-training model to obtain the feature map after dimensionality reduction convolution. Specifically, the encoded feature map is subjected to dimensionality reduction convolution processing by the dimensionality reduction convolution module to obtain the feature map after dimensionality reduction convolution (with a dimension of 28×28×4).

[0032] Step S1013, performing nearest neighbor query and replacement on the feature map after the dimensionality reduction convolution and the features in the code table of the discrete autoencoder pre-training model to obtain multiple feature indexes; each feature index corresponds to a feature in the code table.

[0033] Specifically, the nearest neighbor query method is used to replace the features in the feature map after dimensionality reduction convolution with the features in the code table (using Figure 2 The e1, e2, ..., e shown n The features in the feature map are re-represented), and then the feature index corresponding to each code table feature is obtained. Since each feature index is in the form of an integer, the feature map is discretized into 28×28 integer representations (that is, discrete features are extracted).

[0034] Step S1014: sampling in the code table according to the plurality of feature indices to obtain a discrete feature map. Specifically, in the decoding stage, sampling in the code table according to 28×28 feature indices to obtain a discrete feature map of 28×28×4.

[0035] Step S1015, input the sampled feature map into the dimensionality-increasing convolution module of the discrete autoencoder pre-training model to obtain the feature map after dimensionality-increasing convolution. Specifically, the discrete feature map is processed by the dimensionality-increasing convolution module to obtain a feature map after dimensionality-increasing convolution with a dimension of 28×28×128.

[0036] Step S1016, using the first decoder of the discrete autoencoder pre-trained model, restore the features of the feature map after the dimensionality increase convolution to obtain a reconstructed ultrasound image. Specifically, the feature map after the dimensionality increase convolution passes through the first decoder, and the first decoder is used to restore the features that are specially replaced by the code table to obtain a 224×224×3 reconstructed ultrasound image.

[0037] Step S1017: Calculate a first loss function value according to the historical ultrasound image and the reconstructed ultrasound image, and update the parameters of the discrete autoencoder pre-training model according to the first loss function value.

[0038] Specifically, the goal of training the discrete autoencoder pre-training model is to enable the model to abstract any ultrasound image into 28×28 numbers for representation and restore it to the original image at any time. With the goal of minimizing the gap between the historical ultrasound image and the reconstructed ultrasound image, a loss function is set for training.

[0039] In a possible implementation, the first loss function value is calculated according to the historical ultrasound image and the reconstructed ultrasound image according to the following formula: ; Wherein, x represents the historical ultrasound image, represents the discretized feature map, represents the mean square error loss between the reconstructed ultrasound image and the historical ultrasound image, represents the encoded feature map, e represents the feature in the code table, sg represents not calculating the gradient, is the loss coefficient. Optionally, the loss coefficient It can be 0.25. Further, the above formula can be expanded into the following formula: ; Wherein, x' represents the reconstructed ultrasound image.

[0040] Step S1018, repeat the above steps until the first loss function value converges or reaches a preset number of training times, end the training, and obtain a trained discrete autoencoder pre-training model.

[0041] Specifically, a historical ultrasound image is reselected as training data, and the discrete autoencoder pre-training model is trained according to the above steps S1011-S1017 until the training end condition is met, thereby obtaining a trained discrete autoencoder pre-training model.

[0042] Step S102, constructing a latent space generation model based on the discrete autoencoder pre-training model, wherein the latent space generation model is used to generate an ultrasound image of a corresponding position after the ultrasound navigation action is performed at the current position according to the input current position ultrasound image and ultrasound navigation action.

[0043] Reference Figure 3 , Figure 3 A schematic diagram of the training process of a latent space generation model is shown, such as Figure 3 As shown, the latent space generation model is used to generate an ultrasound image starting from position a corresponding to the ultrasound image A and the action of the ultrasound probe (i.e., ultrasound navigation action B) after the ultrasound probe moves according to the ultrasound navigation action B. Specifically, the latent space generation model includes: a discrete encoder, an embedding layer (such as Figure 3 The "embedding" module shown in the figure), the concatenation module, the encoding module (such as Figure 3 The "Transformer Encoder" module shown in Figure 3 The "Transformer Decoder" module shown in Figure 3 The “Linear” module shown) and the discrete decoder.

[0044] In a possible implementation, the ultrasound navigation action includes at least one of the following: 3 mm translation along the positive direction of the x-axis; 3 mm translation along the negative direction of the x-axis; 3 mm translation along the positive direction of the y-axis; 3 mm translation along the negative direction of the y-axis; 3 mm translation along the positive direction of the z-axis; 3 mm translation along the negative direction of the z-axis; 5 degrees rotation along the positive direction of the x-axis; 5 degrees rotation along the negative direction of the x-axis; 5 degrees rotation along the positive direction of the y-axis; 5 degrees rotation along the negative direction of the y-axis; 5 degrees rotation along the positive direction of the z-axis; 5 degrees rotation along the negative direction of the z-axis; stop action. In this embodiment, the position and direction of the coordinate system composed of the x-axis, y-axis and z-axis can be set according to actual conditions and are not limited in this embodiment.

[0045] Among them, the discrete encoder of the latent space generation model is composed of the first encoder, dimensionality reduction convolution module and code table of the trained discrete autoencoder pre-training model (so that the discrete encoder can discretize the input ultrasound image into 28×28 integer representations); the discrete decoder is composed of the dimensionality increase convolution module, the first decoder and the code table of the trained discrete autoencoder pre-training model (so that the discrete decoder can generate an ultrasound image based on discrete features).

[0046] In a possible implementation, the step S102, constructing a latent space generation model based on the discrete autoencoder pre-training model, includes: Step S1021, input the first ultrasound image into the discrete encoder of the latent space generation model, extract the discrete features, and then obtain the first discrete features through the embedding layer of the latent space generation model; the discrete encoder of the latent space generation model is composed of the first encoder of the discrete autoencoder pre-training model that has been trained, the dimensionality reduction convolution module and the code table.

[0047] Step S1022, input the second ultrasound image into the discrete encoder, extract discrete features, and obtain the second discrete features through the embedding layer of the latent space generation model; the second ultrasound image is an image obtained by performing ultrasound at the ultrasound position corresponding to the first ultrasound image after executing the first ultrasound navigation action.

[0048] Specifically, the first ultrasound navigation action is used to instruct the ultrasound probe to move from position a to position a'. The first ultrasound image refers to the ultrasound image at position a, and the second ultrasound image refers to the ultrasound image at position a'. Through the discrete encoder, discrete features can be extracted from the input first ultrasound image and the second ultrasound image, and discretized into 28×28 integer representations (first discrete features and second discrete features).

[0049] In one possible embodiment, the first ultrasound navigation action includes at least one of the following: a translation of 3 mm along the positive direction of the x-axis; a translation of 3 mm along the negative direction of the x-axis; a translation of 3 mm along the positive direction of the y-axis; a translation of 3 mm along the negative direction of the y-axis; a translation of 3 mm along the positive direction of the z-axis; a translation of 3 mm along the negative direction of the z-axis; a rotation of 5 degrees along the positive direction of the x-axis; a rotation of 5 degrees along the negative direction of the x-axis; a rotation of 5 degrees along the positive direction of the y-axis; a rotation of 5 degrees along the negative direction of the y-axis; a rotation of 5 degrees along the positive direction of the z-axis; a rotation of 5 degrees along the negative direction of the z-axis; and a stop action.

[0050] Step S1023, using the splicing module of the latent space generation model, splicing the first discrete feature and the first ultrasound navigation action, and obtaining the encoding result through the encoding module of the latent space generation model. Figure 3As shown, the first ultrasound navigation action (corresponding to Figure 3 The first discrete feature and the first ultrasonic navigation action are spliced ​​together through the splicing module and sent to the encoder of Transformer (i.e., the encoding module) for encoding processing to obtain the encoding result.

[0051] Step S1024, using the decoding module of the latent space generation model, the encoding result and the second discrete feature are decoded, and a discrete encoding result is obtained through a linear layer. Specifically, the encoding result and the second discrete feature are sent to the decoder (i.e., the decoding module) of the Transformer based on masked self-attention, and after decoding, a discrete encoding result is obtained through a linear layer.

[0052] Step S1025, input the discrete coding result into the discrete decoder of the latent space generation model to obtain the predicted ultrasound image for the first ultrasound navigation action; the discrete decoder is composed of the dimension-increasing convolution module of the trained discrete autoencoder pre-training model, the first decoder and the code table. Specifically, after softmax, the output of the model is 28×28 discrete codes, which can be restored to a pixel-level picture (i.e., a predicted ultrasound image) after passing through the discrete decoder.

[0053] Step S1026: Calculate a second loss function value according to the second ultrasound image and the predicted ultrasound image for the first ultrasound navigation action.

[0054] Specifically, the goal of training the Caintic space generative model is to enable the model to predict the ultrasonic image that can be obtained after executing the ultrasonic navigation action based on the input ultrasonic image and the ultrasonic navigation action. Therefore, the training goal is to minimize the gap between the second ultrasonic image and the predicted ultrasonic image, and a second loss function is set for training.

[0055] Step S1027: According to the second loss function value, on the basis of freezing the discrete encoder and the discrete decoder, update the parameters of the latent space generation model.

[0056] Specifically, a Transformer model is constructed and supervised by autoregression. During the training process, the parameters of the discrete encoder and discrete decoder in the latent space generation model are frozen, and only the parameters of the embedding layer, concatenation module, encoding module, decoding module, and linear layer are updated. The entire training process is completed in the latent space.

[0057] Step S1028, repeat the above steps until the second loss function value converges, or reaches a preset number of training times, end the training, and obtain a trained latent space generation model. Specifically, reselect the first ultrasound image, the first ultrasound navigation action, and the corresponding second ultrasound image as training data, and train the latent space generation model according to the above steps S1021-S1027 until the training end condition is reached, and obtain a trained latent space generation model.

[0058] Step S103: constructing an ultrasound image quality evaluation model based on the discrete autoencoder pre-training model, wherein the ultrasound image quality evaluation model is used to output a quality evaluation result of the ultrasound image according to the input ultrasound image.

[0059] Reference Figure 4 , Figure 4 A schematic diagram of the training process of an ultrasound image quality assessment model is shown in FIG. Figure 4 As shown, the ultrasound image quality evaluation model is used to evaluate whether the input ultrasound image is located in a clear observation window, that is, to evaluate whether the image quality of the current section meets the definition of the standard section. Exemplarily, the final output quality evaluation result can be a score from 0 to 1. The larger the score value, the clearer the observation window corresponding to the ultrasound image is, and the more standard the obtained section is. Specifically, as Figure 4 As shown, the ultrasound image quality assessment model includes: an encoder, a residual unit, a global pooling layer, a linear layer, a splicing module, and a sigmoid module. The encoder of the ultrasound image quality assessment model is composed of the first encoder of the discrete autoencoder pre-training model that has been trained (so that the encoder can discretize the input ultrasound image into a feature map with a dimension of 28×28×128).

[0060] In a possible implementation, the step S103, constructing an ultrasound image quality assessment model based on the discrete autoencoder pre-training model, includes: Step S1031, input the third ultrasound image into the encoder of the ultrasound image quality assessment model to obtain an encoded feature map, wherein the encoder of the ultrasound image quality assessment model is composed of the first encoder of the discrete autoencoder pre-training model that has been trained. Specifically, the third ultrasound image (which can be any 224×224×3 ultrasound image) is input into the ultrasound image quality assessment model to be trained, and after passing through the encoder, an encoded feature map of size 28×28×128 is obtained.

[0061] Step S1032, the encoded feature map is passed through the residual unit and the global pooling layer of the ultrasound image quality assessment model to obtain a pooling result.

[0062] Step S1033: input the onehot representation of the third ultrasound image into the linear layer of the ultrasound image quality assessment model to obtain a first processing result.

[0063] Since ultrasound includes different standard sections, and their visual features vary greatly, the present embodiment adopts condition-based quality evaluation, such as Figure 4 As shown, the onehot representation of the target section (which can be obtained by manual annotation) is used as the input condition (because for an ultrasound image, it can be evaluated or scored according to different evaluation indicators, and different evaluation indicators can obtain different quality evaluation results, the onehot representation is used to characterize the evaluation indicator of the model for evaluating the ultrasound image), through the vector (i.e., the onehot representation), the ultrasound image quality evaluation model is guided to evaluate the corresponding section of the third ultrasound image.

[0064] Step S1034: Obtain a quality evaluation result of the third ultrasound image according to the first processing result and the pooling result. Figure 4 As shown in FIG. 1 , after the extended residual unit and the global pooling layer, the pooling result is obtained. The pooling result is spliced ​​with the first processing result through the splicing module, and then passes through the linear layer and the sigmoid module to obtain the final output quality evaluation result (for example, a score value between 0 and 1, where 0 represents the worst quality and 1 represents the best quality).

[0065] Step S1035: Calculate a third loss function value according to the quality evaluation result of the third ultrasound image.

[0066] Specifically, it can be envisioned that the third ultrasound image is scored by manual annotation, and the scoring result is used as the label of the third ultrasound image. After obtaining the quality evaluation result of the model output, the third loss function is established for training with the minimum gap between the quality evaluation result and the label as the training goal.

[0067] Step S1036: Based on freezing the encoder of the ultrasound image quality assessment model, update parameters according to the third loss function value.

[0068] Specifically, the training process adopts direct regression to perform supervised learning. During the training process, the parameters of the encoder of the ultrasound image quality assessment model are frozen throughout the process, and only the residual unit, global pooling layer, linear layer, splicing module, and sigmoid module of the model are updated.

[0069] Step S1037, repeat the above steps until the third loss function value converges or reaches a preset number of training times, end the training, and obtain a trained ultrasound image quality assessment model. Specifically, reselect the third ultrasound image and the corresponding onehot representation as training data, and train the ultrasound image quality assessment model according to the above steps S1031-S1036 until the training end condition is met, and obtain a trained ultrasound image quality assessment model.

[0070] Step S104: using the latent space generation model and the ultrasound image quality assessment model to train an ultrasound navigation model.

[0071] Specifically, this embodiment regards the ultrasound navigation process as a decision-making process, and the training of the ultrasound navigation model is a process in which an intelligent agent continuously explores and optimizes its strategy in the environment. The current ultrasound position and the ultrasound image at the historical moment are used as the state input at the current moment, and the action predicted by the ultrasound navigation model output (ultrasound navigation action) represents the behavior that the intelligent agent may take in the environment. Among them, the latent space generation model is used as an environmental state transfer model to generate the state at the next moment (that is, the input for generating the ultrasound navigation model at the next moment); the quality evaluation result output by the ultrasound image quality evaluation model is used to define the reward function to evaluate the ultrasound image and feed it back to the navigation model (that is, to evaluate the training effect of the ultrasound navigation model at the current moment). After reaching the preset end condition, the current training cycle is terminated, and a new set of ultrasound images are reacquired for the next training cycle. The ultrasound navigation model continuously updates its understanding of the environment and adjusts its behavior strategy through the above-mentioned continuous cycle training process.

[0072] In a possible implementation, the ultrasound navigation model includes an encoder, and the encoder of the ultrasound navigation model is the first encoder in the discrete autoencoder pre-training model; the step S104, using the latent space generation model and the ultrasound image quality evaluation model to train the ultrasound navigation model, includes: Step S1041 , obtaining the current ultrasound sample image and the historical ultrasound sample images, and generating an ultrasound sample image sequence at the current moment.

[0073] In this embodiment, the training process of the ultrasound navigation model includes multiple training rounds (i.e., training cycles). In different rounds of training, different ultrasound sample image sequences are used for model training. Specifically, the ultrasound navigation model belongs to a sequence model, and the input is a sequence composed of multiple ultrasound sample images in time order (i.e., a sequence composed of one or more historical ultrasound sample images and current ultrasound sample images). When training at the next moment, a new ultrasound sample image is added to the input ultrasound sample image sequence, so that the length of the sequence is increased by 1. As the training rounds increase, the input ultrasound sample image sequence gradually increases, and the maximum length of the sequence is 16. In this embodiment, the historical ultrasound sample images can be stored in the ultrasound navigation model. At the beginning of each training, only the current ultrasound sample image needs to be input, and the stored historical ultrasound sample images can be called accordingly to generate the ultrasound sample image sequence for this round of training.

[0074] Step S1042: input the ultrasound sample image sequence at the current moment into the ultrasound navigation model to obtain a predicted action.

[0075] Specifically, refer to Figure 5 , Figure 5 A schematic diagram of the training process of an ultrasound navigation model is shown, Figure 5 As shown, the ultrasound navigation model includes an encoder and a decoder module (such as Figure 5 The "Transformer Decoder" module shown in the figure), wherein the encoder is composed of the first encoder of the discrete autoencoder pre-trained model that has been trained. The ultrasound sample image sequence at the current moment is input into the decoder of the ultrasound navigation model to obtain the decoding result, and the predicted ultrasound navigation action (such as Figure 5 The predicted action is used to indicate the ultrasound action that should be performed at the ultrasound position corresponding to the current ultrasound sample image to obtain an ultrasound image with a clearer section.

[0076] In one possible embodiment, the predicted action includes at least one of the following: translation 3 mm along the positive direction of the x-axis; translation 3 mm along the negative direction of the x-axis; translation 3 mm along the positive direction of the y-axis; translation 3 mm along the negative direction of the y-axis; translation 3 mm along the positive direction of the z-axis; translation 3 mm along the negative direction of the z-axis; rotation 5 degrees along the positive direction of the x-axis; rotation 5 degrees along the negative direction of the x-axis; rotation 5 degrees along the positive direction of the y-axis; rotation 5 degrees along the negative direction of the y-axis; rotation 5 degrees along the positive direction of the z-axis; rotation 5 degrees along the negative direction of the z-axis; stop action.

[0077] Step S1043: input the predicted action and the current ultrasound sample image into the latent space generation model to obtain a predicted ultrasound image at the next position.

[0078] In this embodiment, the latent space generation model obtains the ultrasonic image (i.e., the predicted ultrasonic image at the next position) that should be obtained after the ultrasonic probe performs the predicted action at the ultrasonic position corresponding to the current ultrasonic sample image based on the input of this round. Exemplarily, the current ultrasonic sample image is an ultrasonic image at position A, and the predicted action represents moving from position A to position B. Then the output of the latent space generation model is the predicted ultrasonic image at position B. Specifically, the current ultrasonic sample image is input into the discrete encoder of the latent space generation model, and after discrete feature extraction, it passes through the embedding layer to obtain the first discrete feature. After the predicted action passes through the embedding layer, the first discrete feature and the predicted action are spliced ​​together through the splicing module, and sent to the encoder (i.e., the encoding module) of the Transformer for encoding processing to obtain the encoding result. The encoding result is passed through the decoding module, the linear layer, and the discrete decoder in sequence to output the predicted ultrasonic image at the next position.

[0079] Step S1044: input the predicted ultrasound image into the ultrasound image quality evaluation model to obtain a quality evaluation result of the predicted ultrasound image.

[0080] In this embodiment, the ultrasound image quality assessment model is based on the input of this round (the predicted ultrasound image of the next position) and the quality assessment result of the image, and the quality assessment result is used to indicate whether the predicted action is correct (if the image quality is poor, it means that the predicted action is incorrect). Specifically, Figure 4 As shown, the predicted ultrasound image is input into the encoder of the ultrasound image quality assessment model, and after discrete feature extraction, it passes through the residual unit and the global pooling layer in sequence to obtain the pooling result. The onehot representation of the predicted ultrasound image passes through the linear layer to obtain the first processing result. The pooling result is spliced ​​with the first processing result through the splicing module, and then passes through the linear layer and the sigmoid module to obtain the final output of the predicted ultrasound image quality assessment result.

[0081] Step S1045 , calculating a reward function according to the quality evaluation result of the predicted ultrasound image, and optimizing parameters of the ultrasound navigation model according to the calculation result of the reward function.

[0082] In a possible implementation, the calculation formula of the reward function is as follows: ; in, is the current ultrasound sample image at the tth moment, is the current ultrasound sample image at the tth moment output by the ultrasound image quality assessment model The quality evaluation results of is the current ultrasound sample image at time t-1, is the current ultrasound sample image at the t-1th moment output by the ultrasound image quality assessment model The quality evaluation results of is a fixed coefficient, Indicates whether to stop the current round of training after the tth time. During the training process, the parameters of the encoder of the ultrasound navigation model are frozen throughout the process, and only the parameters of the decoding module of the model are updated.

[0083] Step S1046, determining whether a preset end condition is met, if the preset end condition is not met, adding the current ultrasound sample image to the historical ultrasound sample image, using the predicted ultrasound image of the next position as the current ultrasound sample image input into the ultrasound navigation model at the next moment, and repeating the above steps until the preset end condition is met.

[0084] In a possible implementation manner, the sequence length of the ultrasound sample image sequence at the next moment is one unit greater than the sequence length of the ultrasound sample image sequence at the current moment; and the preset end condition includes at least one of the following: The calculation result of the reward function meets a preset standard; illustratively, the calculation result of the reward function is greater than or equal to a preset threshold.

[0085] The sequence length of the ultrasound sample image sequence at the current moment reaches a maximum value.

[0086] Specifically, the ultrasound navigation model is a sequence model of fixed length (for example, the length can be 16). When executing the model training at the next moment (for example, according to the model training result at moment t, it is determined that the preset end condition is not met, and the model training at moment t+1 is continued), a new ultrasound sample image is added to the input ultrasound sample image sequence, so that the sequence length is increased by 1. As the training time increases, the input ultrasound sample image sequence gradually increases, and the maximum sequence length of the ultrasound sample image sequence is 16 (that is, a sequence consisting of 16 ultrasound images). In order to maximize the reward, the image quality is continuously improved by adjusting the strategy (action) to achieve the target section, and stop at the appropriate time to obtain additional stop rewards.

[0087] Step S1047, obtaining a new current ultrasound sample image and a historical ultrasound sample image, and repeating the above steps until a preset number of training times is reached, and then the training is terminated to obtain a trained ultrasound navigation model.

[0088] Specifically, in the kth round of model training, after the training at the tth moment is completed, it is determined whether the calculation result of the reward function reaches the preset standard (for example, a preset qualified reward threshold). If the preset standard is reached, the training is stopped. If the preset standard is not reached, it is continued to determine whether the sequence length of the ultrasound sample image sequence at the current moment (the tth moment) reaches the maximum value (for example, 16). If the sequence length of the ultrasound sample image sequence at the current moment (the tth moment) does not reach the maximum value, the ultrasound sample image sequence at the next moment (the t+1th moment) is generated, and the training at the next moment is performed. If the sequence length of the ultrasound sample image sequence at the current moment (the tth moment) reaches the maximum value, the model training of this round (the kth round) is terminated, and a new ultrasound sample image is reselected to perform the model training of the next round (the k+1th round) until the preset number of training times is reached, and the training is terminated to obtain a trained ultrasound navigation model.

[0089] Step S105, inputting the current ultrasound image obtained by ultrasound at the current moment into the ultrasound navigation model to obtain a target ultrasound navigation action, wherein the target ultrasound navigation action is used to indicate the movement action that the ultrasound probe needs to perform at the next moment.

[0090] The embodiment of the present application provides a cardiac ultrasound autonomous navigation method, in which a navigation algorithm drives a manipulator to complete a cross-sectional scan of a real heart, that is, after obtaining a trained ultrasound navigation model through steps S101-S104, the ultrasound navigation model is used to output an ultrasound navigation action according to the real-time input ultrasound image, so that the manipulator (or ultrasound probe) can move or rotate according to the ultrasound navigation action to obtain a clear ultrasound image at an ideal position. The embodiment of the present application improves the decision accuracy of the ultrasound navigation model (that is, the accuracy of the output ultrasound navigation action) by constructing a latent space generation model and an ultrasound image quality evaluation model, supervises the ultrasound navigation model by maximizing rewards, and only relies on the trained ultrasound navigation model for real-time decision making in actual application. On the one hand, the method realizes end-to-end adaptive ultrasound navigation and significantly improves the efficiency of ultrasound examination; on the other hand, the method uses a self-supervised method to train the ultrasound navigation model, which has strong generalization to adapt to individuals with different physical signs and further improve the quality of ultrasound images.

[0091] The second aspect of the embodiment of the present application further provides an ultrasound navigation action determination device, which is used to execute the ultrasound navigation action determination method described in the first aspect of the embodiment of the present application, referring to Figure 6 , Figure 6 A schematic diagram of the structure of an ultrasonic navigation action determination device is shown. Figure 6 As shown, the device comprises: A first construction module is used to train a discrete autoencoder pre-training model using historical ultrasound images, wherein the discrete autoencoder pre-training model is used to extract discrete features from an input ultrasound image and perform image reconstruction based on the discrete features; A second construction module is used to construct a latent space generation model based on the discrete autoencoder pre-training model, wherein the latent space generation model is used to generate an ultrasound image at a corresponding position after the ultrasound navigation action is performed at the current position according to the input ultrasound image at the current position and the ultrasound navigation action; A third construction module is used to construct an ultrasound image quality evaluation model based on the discrete autoencoder pre-training model, and the ultrasound image quality evaluation model is used to output a quality evaluation result of the ultrasound image according to an input ultrasound image; A fourth construction module is used to train an ultrasound navigation model using the latent space generation model and the ultrasound image quality evaluation model; The ultrasound navigation action determination module is used to input the current ultrasound image obtained by ultrasound at the current moment into the ultrasound navigation model to obtain a target ultrasound navigation action, and the target ultrasound navigation action is used to indicate the movement action that the ultrasound probe needs to perform at the next moment. In a possible implementation, the ultrasound navigation model includes an encoder, and the encoder of the ultrasound navigation model is the first encoder in the discrete autoencoder pre-training model; the fourth building module is used to: Acquire the current ultrasound sample image and the historical ultrasound sample images to generate an ultrasound sample image sequence at the current moment; Inputting the ultrasound sample image sequence at the current moment into the ultrasound navigation model to obtain a predicted action; Inputting the predicted action and the current ultrasound sample image into the latent space generation model to obtain a predicted ultrasound image at the next position; Inputting the predicted ultrasound image into the ultrasound image quality evaluation model to obtain a quality evaluation result of the predicted ultrasound image; Calculating a reward function according to a quality evaluation result of the predicted ultrasound image, and optimizing parameters of the ultrasound navigation model according to the calculation result of the reward function; Determine whether a preset end condition is met, and if the preset end condition is not met, add the current ultrasound sample image to the historical ultrasound sample image, use the predicted ultrasound image at the next position as the current ultrasound sample image input into the ultrasound navigation model at the next moment, and repeat the above steps until the preset end condition is met; Acquire new current ultrasound sample images and historical ultrasound sample images, and repeat the above steps until a preset number of training times is reached, then terminate the training and obtain a trained ultrasound navigation model.

[0092] In a possible implementation manner, the sequence length of the ultrasound sample image sequence at the next moment is one unit greater than the sequence length of the ultrasound sample image sequence at the current moment; and the preset end condition includes at least one of the following: The calculation result of the reward function reaches a preset standard; The sequence length of the ultrasound sample image sequence at the current moment reaches a maximum value.

[0093] In a possible implementation, the calculation formula of the reward function is as follows: ; in, is the current ultrasound sample image at the tth moment, is the current ultrasound sample image output by the ultrasound image quality assessment model at the tth moment The quality evaluation results of is the current ultrasound sample image at time t-1, is the current ultrasound sample image at the t-1th moment output by the ultrasound image quality assessment model The quality evaluation results of is a fixed coefficient, Indicates whether to stop the current round of training after the tth moment.

[0094] In a possible implementation manner, the first building block is used to: Inputting the historical ultrasound image into a first encoder of the discrete autoencoder pre-training model to obtain an encoded feature map; Inputting the encoded feature map into the dimension reduction convolution module of the discrete autoencoder pre-training model to obtain the feature map after dimension reduction convolution; Perform nearest neighbor query and replacement on the feature map after the dimensionality reduction convolution and the features in the code table of the discrete autoencoder pre-training model to obtain multiple feature indexes; each feature index corresponds to a feature in the code table; According to the multiple feature indexes, sampling is performed in the code table to obtain a discretized feature map; Inputting the sampled feature map into the dimension-increasing convolution module of the discrete autoencoder pre-training model to obtain the feature map after dimension-increasing convolution; Using the first decoder of the discrete autoencoder pre-training model, restoring the features of the feature map after the dimension-raising convolution, to obtain a reconstructed ultrasound image; Calculating a first loss function value according to the historical ultrasound image and the reconstructed ultrasound image, and updating parameters of the discrete autoencoder pre-training model according to the first loss function value; Repeat the above steps until the first loss function value converges or reaches a preset number of training times, and then terminate the training to obtain a discrete autoencoder pre-training model that has been trained.

[0095] In a possible implementation, the first loss function value is calculated according to the historical ultrasound image and the reconstructed ultrasound image according to the following formula: ; Wherein, x represents the historical ultrasound image, represents the discretized feature map, represents the mean square error loss between the reconstructed ultrasound image and the historical ultrasound image, represents the encoded feature map, e represents the feature in the code table, sg represents not calculating the gradient, is the loss coefficient.

[0096] In a possible implementation manner, the second building module is used to: Inputting the first ultrasound image into the discrete encoder of the latent space generation model, extracting discrete features, and obtaining the first discrete features through the embedding layer of the latent space generation model; the discrete encoder of the latent space generation model is composed of the first encoder of the discrete autoencoder pre-training model that has been trained, the dimensionality reduction convolution module and the code table; The second ultrasonic image is input into the discrete encoder, and after the discrete features are extracted, the second discrete features are obtained by the embedding layer of the latent space generation model; the second ultrasonic image is an image obtained by performing an ultrasonic operation at the ultrasonic position corresponding to the first ultrasonic image after the first ultrasonic navigation action is performed; After splicing the first discrete feature and the first ultrasound navigation action by using the splicing module of the latent space generation model, an encoding result is obtained by using the encoding module of the latent space generation model; Decoding the encoding result and the second discrete feature by using a decoding module of the latent space generation model, and obtaining a discrete encoding result through a linear layer; Inputting the discrete coding result into the discrete decoder of the latent space generation model to obtain a predicted ultrasound image for the first ultrasound navigation action; the discrete decoder is composed of the dimension-raising convolution module of the trained discrete autoencoder pre-training model, the first decoder and the code table; Calculating a second loss function value according to the second ultrasound image and the predicted ultrasound image for the first ultrasound navigation action; According to the second loss function value, on the basis of freezing the discrete encoder and the discrete decoder, updating the parameters of the latent space generation model; Repeat the above steps until the second loss function value converges or reaches a preset number of training times, then end the training to obtain a trained latent space generation model.

[0097] In a possible implementation manner, the third building block is used to: Inputting the third ultrasound image into the encoder of the ultrasound image quality assessment model to obtain an encoded feature map, wherein the encoder of the ultrasound image quality assessment model is composed of the first encoder of the discrete autoencoder pre-trained model that has been trained; The encoded feature map is passed through a residual unit and a global pooling layer of the ultrasound image quality assessment model to obtain a pooling result; Inputting the onehot representation of the third ultrasonic image into the linear layer of the ultrasonic image quality assessment model to obtain a first processing result; Obtaining a quality evaluation result of the third ultrasound image according to the first processing result and the pooling result; Calculating a third loss function value according to a quality evaluation result of the third ultrasonic image; On the basis of freezing the encoder of the ultrasound image quality assessment model, updating parameters according to the third loss function value; The above steps are repeated until the third loss function value converges or reaches a preset number of training times, and the training is terminated to obtain a trained ultrasound image quality evaluation model.

[0098] In a possible implementation, the ultrasound navigation action includes at least one of the following: Translate 3 mm along the positive direction of the x-axis; Translate 3 mm along the negative direction of the x-axis; Translate 3 mm along the positive direction of the y-axis; Translate 3 mm along the negative direction of the y axis; Translate 3 mm along the positive direction of the z-axis; Translate 3 mm along the negative direction of the z-axis; Rotate 5 degrees along the positive direction of the x-axis; Rotate 5 degrees along the negative direction of the x-axis; Rotate 5 degrees along the positive direction of the y axis; Rotate 5 degrees along the negative direction of the y axis; Rotate 5 degrees along the positive direction of the z axis; Rotate 5 degrees along the negative direction of the z axis; Stop the action.

[0099] The present application also provides an electronic device, referring to Figure 7 , Figure 7Schematic diagram of an electronic device proposed in an embodiment of the present application. Figure 7 As shown, the electronic device 100 includes: a memory 110 and a processor 120. The memory 110 and the processor 120 are connected via a bus communication. A computer program is stored in the memory 110. The computer program can be run on the processor 120 to implement the steps in the ultrasonic navigation action determination method disclosed in the embodiment of the present application.

[0100] The embodiment of the present application also provides a computer-readable storage medium on which a computer program / instruction is stored. When the computer program / instruction is executed by a processor, the steps in the ultrasound navigation action determination method disclosed in the embodiment of the present application are implemented.

[0101] The embodiment of the present application also provides a computer program product. When the computer program product is run on an electronic device, the processor implements the steps of the ultrasound navigation action determination method disclosed in the embodiment of the present application.

[0102] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.

[0103] The embodiments of the present application are described with reference to the flowcharts and / or block diagrams of the methods, devices, electronic devices, and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing terminal device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing terminal device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0104] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing terminal device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce a manufactured product including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0105] These computer program instructions can also be loaded onto a computer or other programmable data processing terminal device so that a series of operating steps are executed on the computer or other programmable terminal device to produce a computer-implemented process, thereby providing instructions for executing on the computer or other programmable terminal device to implement the process. Figure 1 A process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.

[0106] Although the preferred embodiments of the present application have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the embodiments of the present application.

[0107] Finally, it should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or terminal device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or terminal device. In the absence of further restrictions, the elements defined by the sentence "including one..." do not exclude the existence of other identical elements in the process, method, article or terminal device including the elements.

[0108] The above is a detailed introduction to an ultrasonic navigation action determination method and device provided by the present application. Specific examples are used in this article to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method of the present application and its core idea; at the same time, for general technical personnel in this field, according to the idea of ​​the present application, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present application.

Claims

1. A method for determining an ultrasound navigation action, characterized in that: The method comprises: Using historical ultrasound images, training a discrete autoencoder pre-training model, wherein the discrete autoencoder pre-training model is used to extract discrete features from an input ultrasound image and perform image reconstruction based on the discrete features; Based on the discrete autoencoder pre-training model, a latent space generation model is constructed, wherein the latent space generation model is used to generate an ultrasound image at a corresponding position after the ultrasound navigation action is performed at the current position according to the input ultrasound image at the current position and the ultrasound navigation action; Based on the discrete autoencoder pre-training model, an ultrasound image quality evaluation model is constructed, wherein the ultrasound image quality evaluation model is used to output a quality evaluation result of the ultrasound image according to an input ultrasound image; Using the latent space generation model and the ultrasound image quality evaluation model, an ultrasound navigation model is trained; The current ultrasound image obtained by performing ultrasound at the current moment is input into the ultrasound navigation model to obtain a target ultrasound navigation action, and the target ultrasound navigation action is used to indicate the movement action that the ultrasound probe needs to perform at the next moment.

2. The method for determining ultrasound navigation actions according to claim 1, characterized in that: The ultrasound navigation model includes an encoder, and the encoder of the ultrasound navigation model is the first encoder in the discrete autoencoder pre-training model; the ultrasound navigation model is obtained by training using the latent space generation model and the ultrasound image quality evaluation model, including: Acquire the current ultrasound sample image and the historical ultrasound sample images to generate an ultrasound sample image sequence at the current moment; Inputting the ultrasound sample image sequence at the current moment into the ultrasound navigation model to obtain a predicted action; Inputting the predicted action and the current ultrasound sample image into the latent space generation model to obtain a predicted ultrasound image at the next position; Inputting the predicted ultrasound image into the ultrasound image quality evaluation model to obtain a quality evaluation result of the predicted ultrasound image; Calculating a reward function according to a quality evaluation result of the predicted ultrasound image, and optimizing parameters of the ultrasound navigation model according to the calculation result of the reward function; Determine whether a preset end condition is met, and if the preset end condition is not met, add the current ultrasound sample image to the historical ultrasound sample image, use the predicted ultrasound image at the next position as the current ultrasound sample image input into the ultrasound navigation model at the next moment, and repeat the above steps until the preset end condition is met; Acquire new current ultrasound sample images and historical ultrasound sample images, and repeat the above steps until a preset number of training times is reached, then terminate the training and obtain a trained ultrasound navigation model.

3. The method for determining ultrasound navigation actions according to claim 2, characterized in that: The sequence length of the ultrasound sample image sequence at the next moment is one unit greater than the sequence length of the ultrasound sample image sequence at the current moment; the preset end condition includes at least one of the following: The calculation result of the reward function reaches a preset standard; The sequence length of the ultrasound sample image sequence at the current moment reaches a maximum value.

4. The method for determining ultrasound navigation actions according to claim 2, characterized in that: The calculation formula of the reward function is as follows: ; in, is the current ultrasound sample image trained at the tth moment, is the current ultrasound sample image at the tth moment output by the ultrasound image quality assessment model The quality evaluation results of is the current ultrasound sample image trained at time t-1, is the current ultrasound sample image at the t-1th moment output by the ultrasound image quality assessment model The quality evaluation results of is a fixed coefficient, Indicates whether to stop the current round of training after the tth moment.

5. The method for determining ultrasound navigation actions according to claim 1, characterized in that: The method of using historical ultrasound images to train a discrete autoencoder pre-training model includes: Inputting the historical ultrasound image into a first encoder of the discrete autoencoder pre-training model to obtain an encoded feature map; Inputting the encoded feature map into the dimension reduction convolution module of the discrete autoencoder pre-training model to obtain the feature map after dimension reduction convolution; Perform nearest neighbor query and replacement on the feature map after the dimensionality reduction convolution and the features in the code table of the discrete autoencoder pre-training model to obtain multiple feature indexes; each feature index corresponds to a feature in the code table; According to the multiple feature indexes, sampling is performed in the code table to obtain a discretized feature map; Inputting the sampled feature map into the dimension-increasing convolution module of the discrete autoencoder pre-training model to obtain the feature map after dimension-increasing convolution; Using the first decoder of the discrete autoencoder pre-training model, restoring the features of the feature map after the dimension-raising convolution, to obtain a reconstructed ultrasound image; Calculating a first loss function value according to the historical ultrasound image and the reconstructed ultrasound image, and updating parameters of the discrete autoencoder pre-training model according to the first loss function value; Repeat the above steps until the first loss function value converges or reaches a preset number of training times, and then terminate the training to obtain a discrete autoencoder pre-training model that has been trained.

6. The method for determining ultrasound navigation actions according to claim 4, characterized in that: According to the following formula, a first loss function value is calculated based on the historical ultrasound image and the reconstructed ultrasound image: ; Wherein, x represents the historical ultrasound image, represents the discretized feature map, represents the mean square error loss between the reconstructed ultrasound image and the historical ultrasound image, represents the encoded feature map, e represents the feature in the code table, sg represents not calculating the gradient, is the loss coefficient.

7. The method for determining ultrasound navigation actions according to claim 5, characterized in that: The step of constructing a latent space generation model based on the discrete autoencoder pre-training model includes: Inputting the first ultrasound image into the discrete encoder of the latent space generation model, extracting discrete features, and obtaining the first discrete features through the embedding layer of the latent space generation model; the discrete encoder of the latent space generation model is composed of the first encoder of the discrete autoencoder pre-training model that has been trained, the dimensionality reduction convolution module and the code table; The second ultrasonic image is input into the discrete encoder, and after the discrete features are extracted, the second discrete features are obtained by the embedding layer of the latent space generation model; the second ultrasonic image is an image obtained by performing an ultrasonic operation at the ultrasonic position corresponding to the first ultrasonic image after the first ultrasonic navigation action is performed; After splicing the first discrete feature and the first ultrasound navigation action by using the splicing module of the latent space generation model, an encoding result is obtained by using the encoding module of the latent space generation model; Decoding the encoding result and the second discrete feature by using a decoding module of the latent space generation model, and obtaining a discrete encoding result through a linear layer; Inputting the discrete coding result into the discrete decoder of the latent space generation model to obtain a predicted ultrasound image for the first ultrasound navigation action; the discrete decoder is composed of the dimension-raising convolution module of the trained discrete autoencoder pre-training model, the first decoder and the code table; Calculating a second loss function value according to the second ultrasound image and the predicted ultrasound image for the first ultrasound navigation action; According to the second loss function value, on the basis of freezing the discrete encoder and the discrete decoder, updating the parameters of the latent space generation model; Repeat the above steps until the second loss function value converges or reaches a preset number of training times, then end the training to obtain a trained latent space generation model.

8. The method for determining ultrasound navigation actions according to claim 5, characterized in that: The method of constructing an ultrasound image quality evaluation model based on the discrete autoencoder pre-training model includes: Inputting the third ultrasound image into the encoder of the ultrasound image quality assessment model to obtain an encoded feature map, wherein the encoder of the ultrasound image quality assessment model is composed of the first encoder of the discrete autoencoder pre-trained model that has been trained; The encoded feature map is passed through a residual unit and a global pooling layer of the ultrasound image quality assessment model to obtain a pooling result; Inputting the onehot representation of the third ultrasonic image into the linear layer of the ultrasonic image quality assessment model to obtain a first processing result; Obtaining a quality evaluation result of the third ultrasound image according to the first processing result and the pooling result; Calculating a third loss function value according to a quality evaluation result of the third ultrasonic image; On the basis of freezing the encoder of the ultrasound image quality assessment model, updating parameters according to the third loss function value; The above steps are repeated until the third loss function value converges or reaches a preset number of training times, and the training is terminated to obtain a trained ultrasound image quality evaluation model.

9. The method for determining ultrasound navigation actions according to claim 1, characterized in that: The ultrasound navigation action includes at least one of the following: Translate 3 mm along the positive direction of the x-axis; Translate 3 mm along the negative direction of the x-axis; Translate 3 mm along the positive direction of the y-axis; Translate 3 mm along the negative direction of the y axis; Translate 3 mm along the positive direction of the z-axis; Translate 3 mm along the negative direction of the z-axis; Rotate 5 degrees along the positive direction of the x-axis; Rotate 5 degrees along the negative direction of the x-axis; Rotate 5 degrees along the positive direction of the y axis; Rotate 5 degrees along the negative direction of the y axis; Rotate 5 degrees along the positive direction of the z axis; Rotate 5 degrees along the negative direction of the z axis; Stop the action.

10. An ultrasonic navigation action determination device, characterized in that: The device for executing the ultrasound navigation action determination method according to any one of claims 1 to 9 comprises: A first construction module is used to train a discrete autoencoder pre-training model using historical ultrasound images, wherein the discrete autoencoder pre-training model is used to extract discrete features from an input ultrasound image and perform image reconstruction based on the discrete features; A second construction module is used to construct a latent space generation model based on the discrete autoencoder pre-training model, wherein the latent space generation model is used to generate an ultrasound image at a corresponding position after the ultrasound navigation action is performed at the current position according to the input ultrasound image at the current position and the ultrasound navigation action; A third construction module is used to construct an ultrasound image quality evaluation model based on the discrete autoencoder pre-training model, and the ultrasound image quality evaluation model is used to output a quality evaluation result of the ultrasound image according to an input ultrasound image; A fourth construction module is used to train an ultrasound navigation model using the latent space generation model and the ultrasound image quality evaluation model; The ultrasound navigation action determination module is used to input the current ultrasound image obtained by ultrasound at the current moment into the ultrasound navigation model to obtain a target ultrasound navigation action, and the target ultrasound navigation action is used to indicate the movement action that the ultrasound probe needs to perform at the next moment.