The application discloses a medical
image segmentation method capable of learning a spectrum prior, and belongs to the technical field of medical
image processing. The method acquires a medical image and performs pretreatment, and then inputs a double-
branch diffusion model trained to extract image condition features; a
mask noise state and a spectrum
noise state are initialized, and joint
reverse diffusion denoising is performed on the two states based on the image condition features; a
mask diffusion branch in the double-
branch diffusion model is used to generate a
mask prediction result, and a spectrum diffusion branch is used to generate a learnable spectrum prior; in the joint
reverse diffusion denoising process, the learnable spectrum prior dynamically guides the generation of the mask prediction result through space-spectrum collaborative updating, and finally a medical
image segmentation result is obtained according to the denoised mask prediction result. In the training stage, the double-branch diffusion model uses an analytical spectrum
anchor point and a structured spectrum statistical target to constrain the spectrum diffusion branch, so that the generated learnable spectrum prior is different from a fixed analytical spectrum.