Hi,
I'm trying to simulate a B-mode ultrasound image from a 3D CT Volume. I basically followed the 'example_us_bmode_linear_transducer.m'. From the documentation and manual, it says that the size of c0 and rho0 should be (Nx, Ny, Nz) in heterogeneous medium. I got sound_speed and density of the 3D volume using the function houndsfield2density.m and replaced the value of c0 and rho0 with these values. But then I got many problems with the code. Seems that the current code just treat c0 and rho0 as single data, not a matrix or scalar. Is there any more detailed instructions on how to implement it?
Thanks so much in advance!
k-Wave
A MATLAB toolbox for the time-domain
simulation of acoustic wave fields
Replace the phantom with a 3D CT Volume
(11 posts) (3 voices)-
Posted 6 years ago #
-
Hi Jing,
The scalar value of
c0
is used at several different places in that script, e.g., to define the input signal, so simply replacingc0
andrho0
won't work. Try replacingmedium.sound_speed
andmedium.density
instead.Brad.
Posted 6 years ago # -
Hi Brad,
Thanks for your prompt reply. I have tried to replace medium.sound_speed and medium.density. When using hounsfield2density.m to get the speed and density, I found that the density sometimes is minus when the ct_data is minus. But in a human body, density should always be positive right?
Another problem now is the position of the transducer. The CT volume I have is a cube that contains the abdomen of a human body and the boundaries are black(consider them as air). How should I set the position of the transducer so that it is on the surface of the abdomen?
Best regards,
JingPosted 6 years ago # -
It's likely that the CT data you are using has the HU scaled differently. Run
hounsfield2density(0, true);
to see the conversion curve used. Unless the air boundary is of specific interest, I would remove the air from the dataset and replace it with water, e.g., by thresholding. Then place the transducer close to the position of interest, where the water simulates a coupling medium.Brad.
Posted 6 years ago # -
Hi Brad,
The air is -1000HU and the water is 0HU. I think the it's the standard scale. If not, what scale should it be to fit the k-Wave toolbox? And thanks for your suggestion of replacing air with water. I will try and see how it works.
Best regards,
JingPosted 6 years ago # -
The function is based on the data in Schneider, U., Pedroni, E., and Lomax A., "The calibration of CT Hounsfield units for radiotherapy treatment planning," Phys. Med. Biol., 41, pp. 111-124 (1996). This defines the scale Hounsfield number as:
H = 1000 * mu_material / mu_water.
Brad.
Posted 6 years ago # -
Hi Brad,
Thank you for your explanation. I have fixed that problem and now I have some new questions.
1. The size of the 3D Phantom is [Nx,Ny+number_scan_lines*transducer.element_width,Nz]. Nz*dz is the actual thickness of the phantom. The simulated B-mode image only shows the middle slice of the phantom. My question is how the thickness affects the simulation? I noticed that in several examples Nz usually equals to Ny. I generally using 2 slices of CT scans to generate the phantom, which means my phantom is quite flate. Is it OK to set Nz much smaller than Ny and Nx(still satisfies the frequency requirements)?
2. I'm trying to simulate US images(abdominal images like kidney,etc) from CT volumes based on the Simulating B-mode Images Example. I have adjusted different parameter settings but still haven't got realistic B-mode images(unable to see clear boundary of the organs). The harmonic images look a little bit better. Do you have any suggestions for improving the simulated images? Or do you have some good examples of simulated images of human body? I have filled air with water(otherwise I got NaN in scan line data). Do you think K-Wave is able to produce bone effect on B-mode ultrasound images(the area after the bone is almost totally black)? Because in the example the maximum speed is 1700m/s while in bone it could be 2000-4000m/s.
3. The simulation takes around 5.3 hours on GPU when my grid size is 512*256*128 for 96 scan lines. Ideally, I would like to generate at least thousands of simulated B-mode images within 1 month(specifically raw RF data), it seems that with current implementation this will take several months. Do you think k-Wave is suitable for this purpose? Or is there any simplification I could adjust in the simulation?
I would greatly appreciate it if you could offer me some ideas on how to deal with these problems.
Best regards,
JingPosted 6 years ago # -
Hi Jing,
1. If you use a very small Nz, you won't be taking into account the slice thickness of the ultrasound image in the elevation plane. Physically, the elements in diagnostic transducers will have some elevation height, and are typically weakly focused in the elevation plane.
2. Have you added scatterers to the CT image? You will need to do this to generate the speckle pattern characteristic of diagnostic US images. Bone isn't a problem per se, you just need to select your discretisation parameters appropriately. E.g., see this paper.
3. Full-wave ultrasound simulation is unfortunately very computationally intensive! Note, each scan line is independent, so you can run the simulations in parallel if you have access to more GPUs. If you want to generate an approximate image, there are other tools you could use for the task.
Hope that helps,
Brad.
Posted 6 years ago # -
Hi Jing,
Would it be possible for you to show one image generated from CT volume? I try it too, but the result is so bad, here is my result, https://www.dropbox.com/s/0l03id12ry5n07c/result.jpg?dl=0
Thanks.Posted 6 years ago # -
Hi dhchen,
I didn't manage to get good results with it. My simulated images look similar to yours. There's no clear boundary of organs on the image. I think it highly depends on how you add scatters and extract acoustic properties from CT. One thing to mention is that raw B-mode images do look like this(I mean the speckles). Further processing steps like denoising and enhancement are needed to have high-quality images.
Best,
JingPosted 6 years ago # -
Hi Jing,
Since Hounsfield unit between liver and lung are close(about 60HU in my data) and the only tool I can use ishounsfield2density
, maybe it is hard to generate clear boundary I guess, and thank for your suggestions.Posted 6 years ago #
Reply
You must log in to post.