Jump to content

Dr. Mike

Administrators
  • Content Count

    1,244
  • Joined

  • Last visited

  • Days Won

    148

Reputation Activity

  1. Like
    Dr. Mike reacted to valchanov for a blog entry, Medical 3D printing 101   
    Bones
     

    The main advantage of the orthopedical presurgical 3d printed models is the possibility to create an accurate model, which can be used for metal osteosynthesis premodelling - the surgeons can prepare (bend, twist, accommodate) the implants prior the operation. After a sterilisation (autoclaving, UV-light, gamma-ray etc etc), those implants can be used in the planned surgery, which will decrease the overall surgery time (in some cases with more than an hour) with all it's advantages, including a dramatic decreasing of the complication rates, the X-ray exposure for the patient and for the surgeons,  the cost and the recovery rates etc etc. For this purpose, you need a smooth bone model, with clearly recognizable and realistic landmarks, realistic measurements and physical properties, close to the real bone. Traditionally, the orthopedical surgeons in my institution used polystyrene models, made by hand, now they have access to 3d printed models and they are better in any way. Here are some tips how to print that thing. 
    1. Method - FDM. The bone models are the easiest and the most forgiving to print. You can make them with literally every printer you can find. FDM is a strong option here and, in my opinion, the best method on choice.
    2. Matherial - PLA - it's cheap, it's easy to print, it's the bread and butter for the bone printing. Cool extruding temperature (195-200C) decrease the stringing and increases the details in the models.
    3. Layer heigh - 0,150mm. This is the best compromise between the print time, the quality and the usability of the models.
    3. Perimeters (shell thickness) - 4 perimeters. One perimeter means one string of 3d printed material. It's width depends on the nozzle diameter and the layer thickness. For Prusa MK3 with 0,4mm nozzle 1 perimeter is ~0,4mm. To achieve a realistic cortical bone, use 4 perimeters (1,7mm). The surgeons loves to cut stuff, including the models, in some cases I have to print several models for training purposes. 4 perimeters PLA feels like a real bone.
    4. Infill - 15% 3d infill (gyroid, cuboid or 3d honey comb). The gyroid is the best - it looks and feels like a spongy bone. It's important to provide a realistic tactile sensation for the surgeons, especially the trainees. They have to be able to feel the moment, when they pass the cortical bone and rush into the spongiosa.
    5. Color - different colors for every fracture fragment. If the model is combined with a 3D visualization, which colors corresponds with the colors of the 3d print, this will make the premodelling work much easier for the surgeons. Also, it looks professional and appealing. 
    6. Postprocessing - a little sanding and a touch of a acrylic varnish will make the model much better.
    7. Support material - every slicer software can generate support, based on the angle between the building platform and the Z axis of the model. You can control this in details with support blockers and support enforcers, which for the bones is not necessary, but it's crucial for the vessels and the heart.
    Conclusions - the bone models are easy to make, they look marvelous and can really change the outcome of every orthopedical surgery.


  2. Like
    Dr. Mike got a reaction from Rachel for a blog entry, 3D Printing a Spine Model to Help a Fellow Doctor with Low Back Pain   
    I was recently contacted by another doctor who asked if I could help him to create a 3D printed replicate of his spine to visualize pinched nerves in his low back and aid with planning a future back surgery. In order to work this doctor has to stand for long hours while performing surgical procedures. Excruciating low back pain had limited his ability to stand to only 30 minutes. As you can imagine, this means he couldn't work. Things only got worse after he had low back surgery.
     
    A CT scan of his lumbar spine (the low back portion of the spine) was performed. It showed that his fifth lumbar vertebra was partially sacralized. This means it looked more like a sacral vertebra than a lumbar vertebra. Was this causing his problem? On the image slices of the CT scan it was difficult to tell.
     
    How the Spine is Organized
    First, a word about the different vertebrae (bones) in the spine. There are four main sections of spinal bones. The seven cervical vertebrae are in the neck and support the head. They are generally small but flexible, and allow rotation of the head. The 12 thoracic vertebrae are in the chest. Their most distinctive characteristic is they all have associated ribs, which make up the rib cage. The five lumbar vertebrae are in the low back. These are large and strong, and designed for supporting lots of weight. They do not have associated ribs. The five sacral vertebrae are in the pelvis. In adults, they are fused together and effectively form a single bone, the sacrum. The coccyx, or tailbone, which is a tiny bone at the bottom end of the vertebral column, can be considered a fifth spinal section. This is the bone that is often injured when you fallen your behind. Figure 1 shows the different sections of the vertebral column.
     

    Figure 1. Sections of the vertebral column. Source:aimisspine.com
     
    Although the bones of the individual sections of the spine usually have their own unique features, it is not uncommon for vertebrae in one section to have features typically associated with an adjacent section. This is particularly true of the vertebrae that are immediately adjacent to a neighboring section. These hybrids are a mix between both sections, are called transitional vertebrae. Do you recall that only thoracic vertebrae have associated ribs? Occasionally the highest lumbar vertebra, L1, will have tiny ribs attached to it. This is a normal variant and is usually harmless. Radiologists who are interpreting medical scans need to be careful to not confuse an L1 vertebra which may have tiny ribs for the adjacent T12 vertebra which normally has ribs. Similarly, the lowest lumbar vertebra, L5, which is normally unfused, can exhibit fusion. As you recall, fusion is a characteristic of sacral vertebrae.
     
    A Congenital Spine Abnormality
    This was the situation with our physician. His lowest lumbar vertebra, L5, has partially fused with S1, the highest sacral vertebra. This condition is congenital. He has had it all his life. The fusion can have the side effect of creating a very narrow bony canal through which the L5 nerve roots can exit the spine. Normally, these nerve roots would have much more space as a large gap would exist between the normally unfused L5 and S1 vertebrae. Was this the problem? The CT scan showed the sacralization of L5, but it was difficult to get a sense for how tight the holes through which the nerves exit, the neural foramina, were. See Figures 2 and 3.
     

     
    Figure 2: Coronal CT image through the L5 and S1 vertebral bodies. Is this the cause of the problem? It is very difficult to get an intuitive sense of what is going on with these flat image slices.
     

     
    Figure 3: Image from Figure 2 with the neural foramina marked.
     
    Seeking help through Embodi3D
    The doctor contacted me through the Embodi3D website and asked if I could create a 3D model design and 3D print of his lumbar spine to help him and his team of spinal specialists understand his unique anatomy better. Of course, I was happy to help. The CT scan was of high quality and allowed me to extract the bones and metallic spinal fusion implants with little trouble. The individual nerves, however, were very difficult to see even on a high quality CT scan. I had to manually segment them one image at a time, which was a very tedious and time-consuming process. After fusing everything together, I had a very good digital model of the lumbar spine. I created some photorealistic 3D renders to illustrate the key findings.
     
    Figures 4 and 5 show the very tight L5-S1 bony neural foramina. The inter-vertebral disc sits within the gap between the two vertebral bodies, and you can see how a lateral bulge from this disc would significantly pinch these exiting nerve roots.
     

     
    Figure 4: Right L5 nerve root (yellow) exiting the tight neural foramen caused by the fused L5 and S1 lateral processes.
     

     
    Figure 5: Left L5 nerve root (yellow) exiting the tight neural foramen caused by the fused L5 and S1 lateral processes.
     
    Additionally, I showed that a bone screw that had been placed during the last surgery had partially exited the L4 vertebral body and was in very close proximity, and probably touching, the adjacent nerve root. Ouch! This can be seen in Figure 6. This may explain why the pain seem to get worse after the last surgery.
     

     
    Figure 6: Transpedicular orthopedic screw which has partially exited the L4 vertebral body and is in very close proximity or in contact with the right L3 nerve root.
     
    The Final 3D Printed Spine Model
    The doctor wanted his spine 3D printed in transparent material, so I used a stereolithographic printer with transparent resin. I printed the spine in two separate parts that could be separated and fit together. When separated, the nerves exiting through the neural foramina can be inspected from inside the spinal canal, which gives an added degree of understanding.
     
    Final pictures of the transparent 3D printed model are shown below.
     
     

     

     
     

     
     

     
     

     
     
     
    I just recently shipped the model to this doctor and don't yet know how his back problems will be resolved. With this 3D printed model in hand however, he will be able to have much more meaningful discussions with his spinal surgeons about the best way to definitively fix his low back problems. I hope that the 3D printed spine model will literally help to get this good doctor back on his feet again.
  3. Like
    Dr. Mike reacted to DevarshVyas for a blog entry, Need of advancements for 3D printing from MRI data   
    Hello the Biomedical 3D Printing community, it's Devarsh Vyas here writing after a really long time! 
     
    This time i'd like to share my personal experience and challenges faced with respect to medical 3D Printing from the MRI data. This can be a knowledge sharing and a debatable topic and I am looking forward to hear and know what other experts here think of this as well with utmost respect. 
     
    In the Just recently concluded RSNA conference at Chicago had a wave of technology advancements like AI and 3D Printing in radiology. Apart from that the shift of radiologists using more and more MR studies for investigations and the advancements with the MRI technology have forced radiologists and radiology centers (Private or Hospitals) to rely heavily on MRI studies.
     
    We are seeing medical 3D Printing becoming mainstream and gaining traction and excitement in the entire medical fraternity, for designers who use the dicom to 3D softwares, whether opensource or FDA approved software know that designing from CT is fairly automated because of the segmentation based on the CT hounsifield units however seldom we see the community discuss designing from MRI, Automation of segmentation from MRI data, Protocols for MRI scan for 3D Printing, Segmentation of soft tissues or organs from MRI data or working on an MRI scan for accurate 3D modeling. 
     
    Currently designing from MRI  is feasible, but implementation is challenging and time consuming. We should also note reading a MRI scan is a lot different than reading a CT scan, MRI requires high level of anatomical knowledge and expertise to be able to read, differentiate and understand the ROI to be 3D Printed. MRI shows a lot more detailed data which maybe unwanted in the model that we design. Although few MRI studies like the contrast MRI of the brain, Heart and MRI angiograms can be automatically segmented but scans like MRI of the spine or MRI of the liver, Kidney or MRI of knee for example would involve a lot of efforts, expertise and manual work to be done in order to reconstruct and 3D Print it just like how the surgeon would want it. 
     
    Another challenge MRI 3D printing faces is the scan protocols, In CT the demand of high quality thin slices are met quite easily but in MRI if we go for protocols for T1 & T2 weighted isotropic data with equal matrix size and less than 1mm cuts, it would increase the scan time drastically which the patient has to bear in the gantry and the efficiency of the radiology department or center is affected. 
     
    There is a lot of excitement to create 3D printed anatomical models from the ultrasound data as well and a lot of research is already being carried out in that direction, What i strongly believe is the community also need advancements in terms of MRI segmentation for 3D printing. MRI, in particular, holds great potential for 3D printing, given its excellent tissue characterization and lack of ionizing radiation but model accuracy, manual efforts in segmentation, scan protocols and expertise in reading and understanding the data for engineers have come up as a challenge the biomedical 3D printing community needs to address. 
     
    These are all my personal views and experiences I've had with 3D Printing from MRI data. I'm open to and welcome any tips, discussions and knowledge sharing from all the other members, experts or enthusiasts who read this. 
     
    Thank you very much! 
  4. Like
    Dr. Mike got a reaction from chinnihuchin for a blog entry, How to create an NRRD file from a DICOM Medical Imaging Data Set   
    NRRD is a file format for storing and visualizing medical image data. Its main benefit over DICOM, the standard file format for medical imaging, is that NRRD files are anonymized and contain no sensitive patient information. Furthermore NRRD files can store a medical scan in a single file, whereas DICOM data sets are usually comprised of a directory or directories that contain dozens if not hundreds of individual files. NRRD is thus a good file for transferring medical scan data while protecting patient privacy. This tutorial will teach you how to create an NRRD file from a DICOM data set generated from a medical scan, such as a CT, MRI, ultrasound, or x-rays.
     
    To complete this tutorial you will need a CD or DVD with your medical imaging scan, or a downloaded DICOM data set from one of many online repositories. If you had a medical scan at a hospital or clinic you can usually obtain a CD or DVD from the radiology department after signing a waiver and paying a small copying fee.
     
    Step 1: Download Slicer
     
    Slicer is a free software program for medical imaging. It can be downloaded from the www.slicer.org. Once on the Slicer homepage, click on the Download link as shown in Figure 1.
     

    Figure 1
     
    Slicer is available for Windows, Mac, and Linux. Choose your operating system and download the latest stable release as shown in Figure 2.
     

    Figure 2: Download Slicer
     
    Step 2: Copy the DICOM files into Slicer.
     
    Insert your CD or DVD containing your medical scan data into your CD or DVD drive, or open the folder containing your DICOM files if you have a downloaded data set. If you navigate into the folder directory, you will notice that there are usually multiple DICOM files in one or more directories, as shown in Figure 3. Navigate to the highest level folder containing all the DICOM files.

    Figure 3: There are many DICOM files in a study
     
    Open Slicer. The welcome screen will show, as demonstrated in Figure 4. Left click on the folder that contains the DICOM files and drop it onto the Welcome panel in Slicer. Slicer will ask you if you want to load the DICOM files into the DICOM database, as shown in Figure 5. Click OK Slicer will then ask you if you want to copy the files or merely add links. Click Copy as shown in Figure 6.

    Figure 4: Drag and drop the DICOM folder onto the Slicer Welcome window.
     

    Figures 5 and 6
     
    After working for a minute or two, Slicer will tell you that the DICOM import was successful, as shown in Figure 7. Click OK

    Figure 7
     
    Step 3: Open the Medical Scan in Slicer.
     
    At this point you should see a window called the DICOM Browser, as shown in Figure 8. The browser has three panels, which show the patient information, study information, and the individual series within each study. If you close the DICOM Browser and need to open it again, you can do so under the Modules menu, as shown in Figure 9.

    Figure 8: DICOM Browser
     

    Figure 9: Finding the DICOM browser
     
    Each series in a medical imaging scan is comprised of a stack of images that together make a volume. This volume can be used to make the NRRD file. Modern CT and MRI scans typically have multiple series and different orientations that were collected using different techniques. These multiple views of the same structures allow the doctors reading the scan to have the best chance of making the correct diagnosis. A detailed explanation of the different types of CT and MRI series is beyond the scope of this article, but will be covered in a future tutorial.
     
    Click on the single patient, study, and a series of interest. Click the Load button as shown in Figure 8. The series will then begin to load as shown in Figure 10.

    Figure 10: The study is loading
     
    Step 4: Save the Imaging Data in NRRD Format
    Once the series loads you will see the imaging data displayed in the Slicer windows. Click the Save button on the upper left-hand corner, as shown in Figure 11.

    Figure 11: Click the Save button
     
    The Save Scene dialog box will then appear. Two or more rows may be shown. Put a checkmark next to the row that has a name that ends in ".nrrd". Uncheck all other rows. Click the directory button for the nrrd file and specify the directory to save the file into. Then click the save button, as shown in Figure 12.

    Figure 12: Check the NRRD file and specify save directory.
     
    The NRRD file will now be saved in the directory you specified!
     
  5. Like
    Dr. Mike got a reaction from jones369 for a blog entry, How to Easily Tell the Difference Between MRI and CT Scan   
    If you are planning on using the democratiz3D service to automatically convert a medical scan to a 3D printable STL model, or you just happen to be working with medical scans for another reason, it is important to know if you are working with a CT (Computed Tomography or CAT) or MRI (Magnetic Resonance Imaging) scan. In this tutorial I'll show you how to quickly and easily tell the difference between a CT and MRI.
     
    I am a board-certified radiologist, and spent years mastering the subtleties of radiology physics for my board examinations and clinical practice. My goal here is not to bore you with unnecessary detail, although I am capable of that, but rather to give you a quick, easy, and practical way to understand the difference between CT and MRI if you are a non-medical person.
     
    Interested in Medical 3D Printing? Here are some resources: Free downloads of hundreds of 3D printable medical models. Automatically generate your own 3D printable medical models from CT scans.  Have a question? Post a question or comment in the medical imaging forum.  A Brief Overview of How CT and MRI Works
    For both CT (left) and MRI (right) scans you will lie on a moving table and be put into a circular machine that looks like a big doughnut. The table will move your body into the doughnut hole. The scan will then be performed. You may or may not get IV contrast through an IV. The machines look very similar but the scan pictures are totally different!

    CT and CAT Scans are the Same
    A CT scan, from Computed Tomography, and a CAT scan from Computed Axial Tomography are the same thing. CT scans are based on x-rays. A CT scanner is basically a rotating x-ray machine that takes sequential x-ray pictures of your body as it spins around. A computer then takes the data from the individual images, combines that with the known angle and position of the image at the time of exposure, and re-creates a three-dimensional representation of the body. Because CT scans are based on x-rays, bones are white and air is black on a CT scan just as it is on an x-ray as shown in Figure 1 below. Modern CT scanners are very fast, and usually the scan is performed in less than five minutes.

    Figure 1: A standard chest x-ray. Note that bones are white and air is black. Miscle and fat are shades of gray. CT scans are based on x-ray so body structures have the same color as they don on an x-ray.
     
    How does MRI Work?
    MRI uses a totally different mechanism to generate an image. MRI images are made using hydrogen atoms in your body and magnets. Yes, super strong magnets. Hydrogen is present in water, fat, protein, and most of the "soft tissue" structures of the body. The doughnut of an MRI does not house a rotating x-ray machine as it does in a CT scanner. Rather, it houses a superconducting electromagnet, basically a super strong magnet. The hydrogen atoms in your body line up with the magnetic field. Don't worry, this is perfectly safe and you won't feel anything. A radio transmitter, yes just like an FM radio station transmitter, will send some radio waves into your body, which will knock some of the hydrogen atoms out of alignment. As the hydrogen nuclei return back to their baseline position they emit a signal that can be measured and used to generate an image.
     
    MRI Pulse Sequences Differ Among Manufacturers
    The frequency, intensity, and timing of the radio waves used to excite the hydrogen atoms, called a "pulse sequence," can be modified so that only certain hydrogen atoms are excited and emit a signal. For example, when using a Short Tau Inversion Recovery (STIR) pulse sequence hydrogen atoms attached to fat molecules are turned off. When using a Fluid Attenuation Inversion Recovery (FLAIR) pulse sequence, hydrogen atoms attached to water molecules are turned off. Because there are so many variables that can be tweaked there are literally hundreds if not thousands of ways that pulse sequences can be constructed, each generating a slightly different type of image. To further complicate the matter, medical scanner manufacturers develop their own custom flavors of pulse sequences and give them specific brand names. So a balanced gradient echo pulse sequence is called True FISP on a Siemens scanner, FIESTA on a GE scanner, Balanced FFE on Philips, BASG on Hitachi, and True SSFP on Toshiba machines. Here is a list of pulse sequence names from various MRI manufacturers. This Radiographics article gives more detail about MRI physics if you want to get into the nitty-gritty.

    Figure 2: Examples of MRI images from the same patient. From left to right, T1, T2, FLAIR, and T1 post-contrast images of the brain in a patient with a right frontal lobe brain tumor. Note that tissue types (fat, water, blood vessels) can appear differently depending on the pulse sequence and presence of IV contrast.
     
    How to Tell the Difference Between a CT Scan and an MRI Scan? A Step by Step Guide
    Step 1: Read the Radiologist's Report
    The easiest way to tell what kind of a scan you had is to read the radiologist's report. All reports began with a formal title that will say what kind of scan you had, what body part was imaged, and whether IV contrast was used, for example "MRI brain with and without IV contrast," or "CT abdomen and pelvis without contrast."
    Step 2: Remember Your Experience in the MRI or CT (CAT) Scanner
    Were you on the scanner table for less than 10 minutes? If so you probably had a CT scan as MRIs take much longer. Did you have to wear earmuffs to protect your hearing from loud banging during the scan? If so, that was an MRI as the shifting magnetic fields cause the internal components of the machine to make noise. Did you have to drink lots of nasty flavored liquid a few hours before the scan? If so, this is oral contrast and is almost always for a CT.
     
    How to tell the difference between CT and MRI by looking at the pictures
    If you don't have access to the radiology report and don't remember the experience in the scanner because the scan was A) not done on you,  or you were to drunk/high/sedated to remember, then you may have to figure out what kind of scan you had by looking at the pictures. This can be complicated, but don't fear I'll show you how to figure it out in this section.
     
    First, you need to get a copy of your scan. You can usually get this from the radiology or imaging department at the hospital or clinic where you had the scan performed. Typically these come on a CD or DVD. The disc may already have a program that will allow you to view the scan. If it doesn't, you'll have to download a program capable of reading DICOM files, such as 3D Slicer. Open your scan according to the instructions of your specific program. You may notice that your scan is composed of several sets of images, called series. Each series contains a stack of images. For CT scans these are usually images in different planes (axial, coronal, and sagittal) or before and after administration of IV contrast. For MRI each series is usually a different pulse sequence, which may also be before or after IV contrast.
     
    Step 3: Does the medical imaging software program tell you what kind of scan you have?
    Most imaging software programs will tell you what kind of scan you have under a field called "modality." The picture below shows a screen capture from 3D Slicer. Looking at the Modality column makes it pretty obvious that this is a CT scan.
     

    Figure 3: A screen capture from the 3D Slicer program shows the kind of scan under the modality column.
     
    Step 4: Can you see the CAT scan or MRI table the patient is laying on?
    If you can see the table that the patient is laying on or a brace that their head or other body part is secured in, you probably have a CT scan. MRI tables and braces are designed of materials that don't give off a signal in the MRI machine, so they are invisible. CT scan tables absorb some of the x-ray photons used to make the picture, so they are visible on the scan.
     

    Figure 4: A CT scan (left) and MRI (right) that show the patient table visible on the CT but not the MRI.
     
    Step 5: Is fat or water white? MRI usually shows fat and water as white.
    In MRI scans the fat underneath the skin or reservoirs of water in the body can be either white or dark in appearance, depending on the pulse sequence. For CT however, fat and water are almost never white. Look for fat just underneath the skin in almost any part of the body. Structures that contained mostly water include the cerebrospinal fluid around the spinal cord in the spinal canal and around the brain, the vitreous humor inside the eyeballs, bile within the gallbladder and biliary tree of the liver, urine within the bladder and collecting systems of the kidneys, and in some abnormal states such as pleural fluid in the thorax and ascites in the abdomen. It should be noted that water-containing structures can be made to look white on CT scans by intentional mixing of contrast in the structures in highly specialized scans, such as in a CT urogram or CT myelogram. But in general if either fat or fluid in the body looks white, you are dealing with an MRI.
     
    Step 6: Is the bone black? CT never shows bones as black.
     
    If you can see bony structures on your scan and they are black or dark gray in coloration, you are dealing with an MRI. On CT scans the bone is always white because the calcium blocks (attenuates) the x-ray photons. The calcium does not emit a signal in MRI scans, and thus appears dark. Bone marrow can be made to also appear dark on certain MRI pulse sequences, such as STIR sequences. If your scan shows dark bones and bone marrow, you are dealing with an MRI.
     
    A question I am often asked is "If bones are white on CT scans, if I see white bones can I assume it is a CT?" Unfortunately not. The calcium in bones does not emit signal on MRI and thus appears black. However, many bones also contain bone marrow which has a great deal of fat. Certain MRI sequences like T1 and T2 depict fat as bright white, and thus bone marrow-containing bone will look white on the scans. An expert can look carefully at the bone and discriminate between the calcium containing cortical bone and fat containing medullary bone, but this is beyond what a layperson will notice without specialized training.
    Self Test: Examples of CT and MRI Scans
    Here are some examples for you to test your newfound knowledge.
    Example 1

    Figure 5A: A mystery scan of the brain
     
    Look at the scan above. Can you see the table that the patient is laying on? No, so this is probably an MRI. Let's not be hasty in our judgment and find further evidence to confirm our suspicion. Is the cerebrospinal fluid surrounding the brain and in the ventricles of the brain white? No, on this scan the CSF appears black. Both CT scans and MRIs can have dark appearing CSF, so this doesn't help us. Is the skin and thin layer of subcutaneous fat on the scalp white? Yes it is. That means this is an MRI. Well, if this is an MRI than the bones of the skull, the calvarium, should be dark, right? Yes, and indeed the calvarium is as shown in Figure 5B. You can see the black egg shaped oval around the brain, which is the calcium containing skull. The only portion of the skull that is white is in the frontal area where fat containing bone marrow is present between two thin layers of calcium containing bony cortex. This is an MRI.
     

    Figure 5B: The mystery scan is a T1 spoiled gradient echo MRI image of the brain. Incidentally this person has a brain tumor involving the left frontal lobe.
     
    Example 2

    Figure 6A: Another mystery scan of the brain
     
    Look at the scan above. Let's go through our process to determine if this is a CT or MRI. First of all, can you see the table the patient is lying on or brace? Yes you can, there is a U-shaped brace keeping the head in position for the scan. We can conclude that this is a CT scan. Let's investigate further to confirm our conclusion. Is fat or water white? If either is white, then this is an MRI. In this scan we can see both fat underneath the skin of the cheeks which appears dark gray to black. Additionally, the material in the eyeball is a dark gray, immediately behind the relatively white appearing lenses of the eye. Finally, the cerebrospinal fluid surrounding the brainstem appears gray. This is not clearly an MRI, which further confirms our suspicion that it is a CT. If indeed this is a CT, then the bones of the skull should be white, and indeed they are. You can see the bright white shaped skull surrounding the brain. You can even see part of the cheekbones, the zygomatic arch, extending forward just outside the eyes. This is a CT scan.
     

    Figure 6B: The mystery scan is a CT brain without IV contrast.
     
    Example 3

    Figure 7A: A mystery scan of the abdomen
     
    In this example we see an image through the upper abdomen depicting multiple intra-abdominal organs. Let's use our methodology to try and figure out what kind of scan this is. First of all, can you see the table that the patient is laying on? Yes you can. That means we are dealing with the CT. Let's go ahead and look for some additional evidence to confirm our suspicion. Do the bones appear white? Yes they do. You can see the white colored thoracic vertebrae in the center of the image, and multiple ribs are present, also white. If this is indeed a CT scan than any water-containing structures should not be white, and indeed they are not. In this image there are three water-containing structures. The spinal canal contains cerebrospinal fluid (CSF). The pickle shaped gallbladder can be seen just underneath the liver. Also, this patient has a large (and benign) left kidney cyst. All of these structures appear a dark gray. Also, the fat underneath the skin is a dark gray color. This is not in MRI. It is a CT.
     

    Figure 7B: The mystery scan is a CT of the abdomen with IV contrast
     
    Example 4

    Figure 8A: A mystery scan of the left thigh
     
    Identifying this scan is challenging. Let's first look for the presence of the table. We don't see one but the image may have been trimmed to exclude it, or the image area may just not be big enough to see the table. We can't be sure a table is in present but just outside the image. Is the fat under the skin or any fluid-filled structures white? If so, this would indicate it is an MRI. The large white colored structure in the middle of the picture is a tumor. The fat underneath the skin is not white, it is dark gray in color. Also, the picture is through the mid thigh and there are no normal water containing structures in this area, so we can't use this to help us. Well, if this is a CT scan than the bone should be white. Is it? The answer is no. We can see a dark donut-shaped structure just to the right of the large white tumor. This is the femur bone, the major bone of the thigh and it is black. This cannot be a CT. It must be an MRI. This example is tricky because a fat suppression pulse sequence was used to turn the normally white colored fat a dark gray. Additionally no normal water containing structures are present on this image. The large tumor in the mid thigh is lighting up like a lightbulb and can be confusing and distracting. But, the presence of black colored bone is a dead giveaway. 
     

    Figure 8B: The mystery scan is a contrast-enhanced T2 fat-suppressed MRI
     
    Conclusion: Now You Can Determine is a Scan is CT or MRI
    This tutorial outlines a simple process that anybody can use to identify whether a scan is a CT or MRI. The democratiz3D service on this website can be used to convert any CT scan into a 3D printable bone model. Soon, a feature will be added that will allow you to convert a brain MRI into a 3D printable model. Additional features will be forthcoming. The service is free and easy to use, but you do need to tell it what kind of scan your uploading. Hopefully this tutorial will help you identify your scan.
     
    If you'd like to learn more about the democratiz3D service click here. Thank you very much and I hope you found this tutorial to be helpful.
     
    Nothing in this article should be considered medical advice. If you have a medical question, ask your doctor.
     
  6. Like
    Dr. Mike got a reaction from Angel Sosa for a blog entry, 3D Printing Tutorial: Introduction to Free and Open-Source Software, 3D Slicer, MeshMixer, democratiz3D. From the 2018 RSNA Meeting   
    This tutorial is based on course I taught at the 2018 RSNA meeting in Chicago, Illinois. It is shared here free to the public. In this tutorial, we walk though how to convert a CT scan of the face into a 3D printable file, ready to be sent to a 3D printer. The patient had a gunshot wound to the face. We use only free or open-source software and services for this tutorial.
     
    There are two parts to this tutorial:
    Part 1: How to use free desktop software to create your model Part 2: Use embodi3D's free democratiz3D service to automatically create your model  

     
    Key Takeaway from this Tutorial:
    You can make high quality 3D printable models from medical imaging scans using FREE software and services, and it is surprisingly EASY.
     
     
    A note on the FDA (for USA people):
    There is a lot of confusion about whether expensive, FDA-approved software must be used for medically-related 3D printing in the United States. The FDA recently clarified its stance on the issue.* If you are not using these models for patient-care purposes, this does not concern you. If you have questions please see the FDA website.
     
     
    If you are a DOCTOR, you can use whatever software you think is appropriate for your circumstances under your practice of medicine. If you are a COMPANY, selling 3D printed models for diagnostic use, you need FDA-approved software. If you are designing implants or surgical cutting guides, those are medical devices. Seek FDA feedback.  
    *Kiarashi, N. FDA Current Practices and Regulations, FDA/CDRH-RSNA SIG Meeting on 3D Printed Patient-
    Specific Anatomic Models. Available at https://www.fda.gov/downloads/MedicalDevices/NewsEvents/WorkshopsConferences/UCM575723.pdf Accessed 11/1/2017.
     
    Part 1: Using Desktop software 3D Slicer and Meshmixer

    Step 1: Download the scan file and required software
    To start, download the starting CT scan file at the link below. Also, install 3D Slicer (slicer.org) and Meshmixer (meshmixer.com).
     
     
    Step 2: Open 3D Slicer
    Open Slicer. Drag and drop the scan file gunshot to face.nrrd onto the slicer window. The scan should open in a 4 panel view as shown below in Figure 1.

    Figure 1: The 4 up view.
     
    If your view does not look like this, you can set the 4 up view to display by clicking Four-Up from the View menu, as shown in Figure 2
     

    Figure 2: Choosing the four-up view
     
    Step 3: Learning to control the interface
    Slicer has basic interface controls. Try them out and become accustomed to how the interface works. Note how the patient has injuries from gunshot wound to the face.
    Left mouse button – Window/Level Right mouse button – Zoom Scroll wheel – Scroll through stack Middle mouse button -- Pan  
    Step 4: Blur the image
    The CT scan was created using a bone reconstruction kernel. Basically this is an image-enhancement algorithm that makes edges more prominent, which makes detection of fractures easier to see by the human eye. While making fracture detection easier, this algorithm does unnaturally alter the image and makes it appear more "speckled" 
     

    Figure 3: Noisy, "speckled" appearance of the scan on close up view
     
    To fix this issue, we will slightly blur the image. Select Gaussian Blur Image Filter as shown below in Figure 4
     

    Figure 4: Choosing the Gaussian Blur Image Filter
     
    Set up the Gaussian Blur parameters. Set Sigma = 1.0. Set the input volume to be Gunshot to face. Create a new output volume called "Gaussian volume" as shown in Figure 5.
     

    Figure 5: Setting up the Gaussian parameters
     
    When ready, click Apply, as shown in Figure 6. You will notice that the scan becomes slightly blurred.

    Figure 6: Click Apply to start the Gaussian Blur Image filter.
     
    Step 5: Create a 3D model using Grayscale Model Maker
     
    Open the Grayscale Model Maker Module as shown below in Figure 7.
     

    Figure 7: Opening the Grayscale Model Maker
     
    Set up the Grayscale Model Maker parameters. Select the Gaussian volume as the input volume, as shown in Figure 8.
     

    Figure 8: Choosing the input volume in Grayscale Model Maker

    Next, set the output geometry to be a new model called "gunshot model." Set the other parameters: Threshold = 200, smooth 15, Decimate 0.5, Split normals unchecked as shown in Figure 9.

    Figure 9: Grayscale Model maker parameters
     
    When done, click Apply. A new model should be created and will be shown in the upper right hand panel, as shown in Figure 10.

    Figure 10: The new model
     
    Step 6: Save the model as an STL file
     
    To start saving the model, click the save button in the upper left of the Slicer window as shown in Figure 11.

    Figure 11: The save button
     
    Be sure that only the 3D model, gunshot model.vtk is selected. Uncheck everything else, as shown in Figure 12.
     

    Figure 12: The Save dialog. Check the vtk file
     
    Make sure the format of the 3D model is STL as shown in Figure 13. Specify the folder to save into, as shown in Figure 14.

    Figure 13: Specify the file type
     

    Figure 14: Specify the folder to save into within the Save dialog.
     
    Step 7: Open the file in Meshmixer for cleanup
     
    Open Meshmixer. Drag and drop the newly created STL file on the meshmixer window. The file will open and the model will be displayed as in Figure 15.
     

    Figure 15: open the STL file in Meshmixer
     
    Get accustomed to the Meshmixer interface as shown in Figure 16. A 3 button mouse is very helpful.

    Figure 16: Controlling the Meshmixer user interface
     
    Choose the Select tool. In is the arrow button along the left of the window.

    Figure 17: The select tool
     
    Click on a portion of the model. The selected portion will turn orange, as shown in Figure 18.

    Figure 18: Selected areas turn orange.
     
    Expand the small selected area to all mesh connected to it. Use Select->Modify->Expand to Connected, or hit the E key. The entire model should turn orange. See Figure 19.
     

    Figure 19: Expanding the selection to all connected mesh.
     
    Next, Invert the selection so that only disconneced, unwanted mesh is selected. Do this with Select->Modify->Invert, or hit the I key as shown in Figure 20.

    Figure 20: Inverting the selection
     
    At this point, only the unwanted, disconnected mesh should be selected in orange. Delete the unwanted mesh using Select->Edit->Discard, or use the X or DELETE key as shown in Figure 21. At this point, only the desired mesh should remain.

    Figure 21: Deleting unwanted mesh.
     
    Step 8: Run the Inspector tool
     
    The Inspector tool will automatically fix most errors in the model mesh. To open it, choose Analysis->Inspector as shown in Figure 22.

    Figure 22: The Inspector tool
     
    The Inspector will identify all of the errors in the mesh. To automatically correct these mesh errors, click Auto Repair All as shown in Figure 23.
     

    Figure 23: Auto Repairing using Inspector
     
    The Inspector will usually fix all or most errors. In this case however, there is a large hole at the edge of the model where the border of the scan zone was. The Inspector doesn't know how to close it. This is shown in Figure 24.
     

    Figure 24: The inspect could not fix 1 mesh error
     
    Step 9: Close the remaining hole with manual bridges
     
    Using the select tool, select a zone of mesh near the open edge. The Select tool is opened with the arrow button along the left. Choose a brush size -- 40 is good -- as shown in Figure 25.
     

    Figure 25: Choosing the select tool
     
    The mesh should turn orange when selected, as shown in Figure 26.
     

    Figure 26: Selected mesh turns orange.
     
    Next, rotate the model and select a zone of mesh opposite the edge from the first selected zone, as shown in Figure 27. 

    Figure 27: Selecting mesh opposite the defect.
     
    Once both edges are selected, create a bridge of mesh spanning the two selected areas using the Bridge operation: Select->Edit->Bridge, or CTRL-B, as shown in Figure 28.
    Figure 28: The bridge tool
     
    There should now be a bridge of orange mesh spanning the gap. Click Accept, as shown in Figure 29.

    Figure 29: The new bridge. Be sure to click Accept.
     
    Next, repeat the bridge on the opposite side of the skull. Be sure to deselect the previously selected mesh before working on the opposite side, as shown in Figure 30.

    Figure 30: Creating a second bridge on the opposite side.
     
    Step 10: Rerun the Inspector
     
    Rerun the Inspector tool, as shown in Figure 31. Now with the bridges to "help" Meshmixer to know how to fill in the hole, it should succeed. If it fails, create more bridges and try again.
     

    Figure 31: Rerun the Inspector tool
     
    Next, export your file to STL. 
    '
    Figure 32: Export to STL
     
    Step 11: 3D print your file!
     
    Your STL file is now ready to be sent to the 3D printer of your choice. Figure 33 shows the model after printing.

    Figure 33: The final print
     
    Part 2: Using the democratiz3D service on embodi3d.com
     
    democratiz3D automatically converts scans to 3D printable models. It automates the mesh cleanup process and saves time. The service is free for general bone model creation. 
     
    Step 1: Register
    Register for a free embodi3D account. The process takes only a minute. You need an account for your processed files to be saved to.
     
    Step 2: Upload the NRRD source scan to democratiz3D.
     
    From anywhere in the site, click democratiz3D-> Launch App
     

    Figure 34: Launching the democratiz3D app.
     
    Fill out basic information about your file. That information will be copied to your generated STL file, as shown in Figure 35.
     

    Figure 35: Entering basic file information
     
    Make sure democratiz3D processing is on. Choose an operation to convert your model. Set threshold to 200, as shown in Figure 36.
    Figure 36: Operation, threshold, and quality parameters.
     
    Click Submit! In 10 to 15 minutes your model should be done. You will receive an email notification. The completed model file will be saved under your account. Download the file and send it to your printer of choice!
     

    Figure 37; The final democratiz3D file, ready for download.
     
    That's it! I hope this tutorial was helpful to you. If you liked it, please rate it positively. If you want to learn more about democratiz3D, Meshmixer, or Slicer, please see our tutorials page. It has a lot of wonderful resources. Happy 3D printing!
     

  7. Like
    Dr. Mike got a reaction from Ariadna for a blog entry, How to Convert Multiple 3D Printable Bone Model STL Files from a CT Scan   
    Please note that any references to “Imag3D” in this tutorial has been replaced with “democratiz3D”
     
    In this tutorial you will learn how to create multiple 3D printable bone models simultaneously using the free online CT scan to bone STL converter, democratiz3D. We will use the free desktop program Slicer to convert our CT scan in DICOM format to NRRD format. We will also make a small section of the CT scan into its own NRRD file to create a second stand-alone model. The NRRD files will then be uploaded to the free democratiz3D online service to be converted into 3D printable STL models.
     
    If you haven't already, please see the tutorial A Ridiculously Easy Way to Convert CT Scans to 3D Printable Bone STL Models for Free in Minutes, which provides a good overview of the democratiz3D service.
     
    You should download the file pack that accompanies this tutorial. This contains an anonymized DICOM data set that will allow you to follow along with the tutorial.
     
    >>> DOWNLOAD THE TUTORIAL FILE PACK <<<
     
     
     
     
    Step 1: Register for an Embodi3D account

     
    If you haven't already done so, you'll need to register for an embodi3D account. Registration is free and only takes a minute. Once you are registered you'll receive a confirmatory email that verifies you are the owner of the registered email account. Click the link in the email to activate your account. The democratiz3D service will use this email account to send you notifications when your files are ready for download.
     
    Step 2: Create NRRD Files from DICOM with Slicer
     
    Open Slicer, which can be downloaded for free from www.slicer.org. Take the folder that contains your DICOM scan files and drag and drop it onto the slicer window, as shown in Figure 1. If you downloaded the tutorial file pack, a complete DICOM data set is included. Click OK when asked to load the study into the DICOM database. Click Copy when asked if you want to copy the images into the local database directory. Remember, this only works with CT scans. MRIs cannot be converted at this time.
     

    Figure 1: Dragging and dropping the DICOM folder onto the Slicer application. This will load the CT scan.
     
    A NRRD file that encompasses the entire scan can easily be created by clicking the save button at this point. Before we do that however, we are going to create a second NRRD file that only contains the lumbar spine, which will allow us to create a second 3D printable bone model of the lumbar spine. Open the CT scan by clicking on the Show DICOM Browser button, selecting the scan and series within the scan, and clicking the Load button. The CT scan will then load within the multipanel viewer.
     
    From the drop-down menu at the top left of the Slicer window, select All Modules and then Crop Volume, as shown in Figure 2. You will now want to create a Region Of Interest (ROI) to encompass the smaller volume we want to make. Turn on the ROI visibility button and then under the Input ROI drop-down menu, select "Create new AnnotationROI," As shown in Figure 3.
     

    Figure 2: Choosing the Crop Volume module
     

    Figure 3: Turn on ROI visibility and Create a new AnnotationROI under the Input ROI drop-down menu.
     
    A small cube will then be displayed in the blue volume window. This represents the sub volume that will be made. In its default position, the cube may not overlay the body, and may need to be dragged downward. Grab a control point on the cube and drag it downward (inferiorly) as shown in Figure 4.

    Figure 4: Grab the sub volume ROI and drag it downwards until it overlaps with the body.
     
    Next, use the control points on the volume box to position the volume box over the portion of the scan you wish to be included in the small 3D printable model, as shown in Figure 5.

    Figure 5: Adjusting the control points on the crop volume box.
     
    Once you have the box position where you want it, initiate the volume crop by clicking the Crop! button, as shown in Figure 6.

    Figure 6: The Crop! button
     
    You have now have two scan volumes that can be 3D printed. The first is the entire scan, and the second is the smaller sub volume that contains only the lumbar spine. We are now going to save those individual volumes as NRRD files. Click the Save button in the upper left-hand corner. In the Save Scene window, uncheck all items that do not have NRRD as the file format, as shown in Figure 7. Only NRRD file should be checked. Be sure to specify the directory that you want each file to be saved in.
     

    Figure 7: The Save Scene window
     
    Your NRRD files should now be saved in the directory you specified.
     
    Step 3: Upload your NRRD files and Convert to STL Files Using the Free democratiz3D Service
     
    Launch your web browser and go to www.embodi3d.com. If you haven't already register for a account. Registration is free and only takes a minute. Click on the democratiz3D navigation item and select Launch App, as shown in Figure 8.
     

    Figure 8: launching the democratiz3D application.
     
    Drag-and-drop both of your NRRD files onto the upload panel. Fill in the required fields, including a title, short description, privacy setting (private versus shared), and license type. You must agree to the terms of use. Please note that even though license type is a required field, it only matters if the file is shared. If you keep the file private and thus not available to other members on the site, they will not see it nor be able to download it.
     
    Be sure to turn on the democratiz3D Processing slider! If you don't turn this on your file will not be processed but will just be saved in your account on the website. It should be green when turned on. Once you turn on democratiz3D Processing, you'll be presented with some basic processing options, as shown in Figure 9. Leave the default operation as "CT NRRD to Bone STL," which is the operation that creates a basic bone model from a CT scan in NRRD format. Threshold is the Hounsfield attenuation to use for selecting the bones. The default value of 150 is good for most applications, but if you have a specialized model you wish to create, you can adjust this value. Quality denotes the number of polygons in your output file. High-quality may take longer to process and produce larger files. These are more appropriate for very large or detailed structures, such as an entire spinal column. Low quality is best for small structures that are geometrically simple, such as a patella. Medium quality is balanced, and is appropriate for most circumstances.
     

    Figure 9: The democratiz3D File Processing Parameters.
     
    Once you are satisfied with your processing parameters, click submit. Both of your nrrd files will be processed in two separate bone STL files, as shown in Figure 10. The process takes 10 to 20 minutes and you will receive an email notifying you that your files are ready. Please note, the stl processing will finish first followed by the images. Click on the thumbnails for each model to access the file for download or click the title.
     

    Figure 10:  Two files have been processed simultaneously and are ready for download
     
    Step 4: CT scan conversion is complete your STL bone model files are ready for 3D Printing
    That's it! Both of your bone models are ready for 3D printing. I hope you enjoyed this tutorial. Please use the democratiz3D service and  SHARE the files you create with the community by changing their status from private or shared. Thank you very much and happy 3D printing!
  8. Like
    Dr. Mike got a reaction from Sachal for a blog entry, How to Create a Hollow Shell from a Medical STL File Using MeshMixer   
    In this brief tutorial we will go over how to use Meshmixer to create a hollow shell from a medical 3D printable STL file. Hollowing out the shell, as shown in the pictures below, can allow you to 3D print the model using much less material that printing a solid piece. The print will take less time and cost less money.
     
    For this tutorial we will use a head that we created from a real medical CT scan in a prior tutorial, " Easily Create 3D Printable Muscle and Skin STL Files from Medical CT Scans" If you haven't seen the prior tutorial, please check it out.
     

     
    To follow along with the tutorial, please download the accompanying file. This will enable you to replicate the process exactly as it is shown in the tutorial. 
     
    >> DOWNLOAD THE TUTORIAL FILE NOW <<
     
     
     
  9. Like
    Dr. Mike got a reaction from mikefazz for a blog entry, How to Easily Tell the Difference Between MRI and CT Scan   
    If you are planning on using the democratiz3D service to automatically convert a medical scan to a 3D printable STL model, or you just happen to be working with medical scans for another reason, it is important to know if you are working with a CT (Computed Tomography or CAT) or MRI (Magnetic Resonance Imaging) scan. In this tutorial I'll show you how to quickly and easily tell the difference between a CT and MRI.
     
    I am a board-certified radiologist, and spent years mastering the subtleties of radiology physics for my board examinations and clinical practice. My goal here is not to bore you with unnecessary detail, although I am capable of that, but rather to give you a quick, easy, and practical way to understand the difference between CT and MRI if you are a non-medical person.
     
    Interested in Medical 3D Printing? Here are some resources: Free downloads of hundreds of 3D printable medical models. Automatically generate your own 3D printable medical models from CT scans.  Have a question? Post a question or comment in the medical imaging forum.  A Brief Overview of How CT and MRI Works
    For both CT (left) and MRI (right) scans you will lie on a moving table and be put into a circular machine that looks like a big doughnut. The table will move your body into the doughnut hole. The scan will then be performed. You may or may not get IV contrast through an IV. The machines look very similar but the scan pictures are totally different!

    CT and CAT Scans are the Same
    A CT scan, from Computed Tomography, and a CAT scan from Computed Axial Tomography are the same thing. CT scans are based on x-rays. A CT scanner is basically a rotating x-ray machine that takes sequential x-ray pictures of your body as it spins around. A computer then takes the data from the individual images, combines that with the known angle and position of the image at the time of exposure, and re-creates a three-dimensional representation of the body. Because CT scans are based on x-rays, bones are white and air is black on a CT scan just as it is on an x-ray as shown in Figure 1 below. Modern CT scanners are very fast, and usually the scan is performed in less than five minutes.

    Figure 1: A standard chest x-ray. Note that bones are white and air is black. Miscle and fat are shades of gray. CT scans are based on x-ray so body structures have the same color as they don on an x-ray.
     
    How does MRI Work?
    MRI uses a totally different mechanism to generate an image. MRI images are made using hydrogen atoms in your body and magnets. Yes, super strong magnets. Hydrogen is present in water, fat, protein, and most of the "soft tissue" structures of the body. The doughnut of an MRI does not house a rotating x-ray machine as it does in a CT scanner. Rather, it houses a superconducting electromagnet, basically a super strong magnet. The hydrogen atoms in your body line up with the magnetic field. Don't worry, this is perfectly safe and you won't feel anything. A radio transmitter, yes just like an FM radio station transmitter, will send some radio waves into your body, which will knock some of the hydrogen atoms out of alignment. As the hydrogen nuclei return back to their baseline position they emit a signal that can be measured and used to generate an image.
     
    MRI Pulse Sequences Differ Among Manufacturers
    The frequency, intensity, and timing of the radio waves used to excite the hydrogen atoms, called a "pulse sequence," can be modified so that only certain hydrogen atoms are excited and emit a signal. For example, when using a Short Tau Inversion Recovery (STIR) pulse sequence hydrogen atoms attached to fat molecules are turned off. When using a Fluid Attenuation Inversion Recovery (FLAIR) pulse sequence, hydrogen atoms attached to water molecules are turned off. Because there are so many variables that can be tweaked there are literally hundreds if not thousands of ways that pulse sequences can be constructed, each generating a slightly different type of image. To further complicate the matter, medical scanner manufacturers develop their own custom flavors of pulse sequences and give them specific brand names. So a balanced gradient echo pulse sequence is called True FISP on a Siemens scanner, FIESTA on a GE scanner, Balanced FFE on Philips, BASG on Hitachi, and True SSFP on Toshiba machines. Here is a list of pulse sequence names from various MRI manufacturers. This Radiographics article gives more detail about MRI physics if you want to get into the nitty-gritty.

    Figure 2: Examples of MRI images from the same patient. From left to right, T1, T2, FLAIR, and T1 post-contrast images of the brain in a patient with a right frontal lobe brain tumor. Note that tissue types (fat, water, blood vessels) can appear differently depending on the pulse sequence and presence of IV contrast.
     
    How to Tell the Difference Between a CT Scan and an MRI Scan? A Step by Step Guide
    Step 1: Read the Radiologist's Report
    The easiest way to tell what kind of a scan you had is to read the radiologist's report. All reports began with a formal title that will say what kind of scan you had, what body part was imaged, and whether IV contrast was used, for example "MRI brain with and without IV contrast," or "CT abdomen and pelvis without contrast."
    Step 2: Remember Your Experience in the MRI or CT (CAT) Scanner
    Were you on the scanner table for less than 10 minutes? If so you probably had a CT scan as MRIs take much longer. Did you have to wear earmuffs to protect your hearing from loud banging during the scan? If so, that was an MRI as the shifting magnetic fields cause the internal components of the machine to make noise. Did you have to drink lots of nasty flavored liquid a few hours before the scan? If so, this is oral contrast and is almost always for a CT.
     
    How to tell the difference between CT and MRI by looking at the pictures
    If you don't have access to the radiology report and don't remember the experience in the scanner because the scan was A) not done on you,  or you were to drunk/high/sedated to remember, then you may have to figure out what kind of scan you had by looking at the pictures. This can be complicated, but don't fear I'll show you how to figure it out in this section.
     
    First, you need to get a copy of your scan. You can usually get this from the radiology or imaging department at the hospital or clinic where you had the scan performed. Typically these come on a CD or DVD. The disc may already have a program that will allow you to view the scan. If it doesn't, you'll have to download a program capable of reading DICOM files, such as 3D Slicer. Open your scan according to the instructions of your specific program. You may notice that your scan is composed of several sets of images, called series. Each series contains a stack of images. For CT scans these are usually images in different planes (axial, coronal, and sagittal) or before and after administration of IV contrast. For MRI each series is usually a different pulse sequence, which may also be before or after IV contrast.
     
    Step 3: Does the medical imaging software program tell you what kind of scan you have?
    Most imaging software programs will tell you what kind of scan you have under a field called "modality." The picture below shows a screen capture from 3D Slicer. Looking at the Modality column makes it pretty obvious that this is a CT scan.
     

    Figure 3: A screen capture from the 3D Slicer program shows the kind of scan under the modality column.
     
    Step 4: Can you see the CAT scan or MRI table the patient is laying on?
    If you can see the table that the patient is laying on or a brace that their head or other body part is secured in, you probably have a CT scan. MRI tables and braces are designed of materials that don't give off a signal in the MRI machine, so they are invisible. CT scan tables absorb some of the x-ray photons used to make the picture, so they are visible on the scan.
     

    Figure 4: A CT scan (left) and MRI (right) that show the patient table visible on the CT but not the MRI.
     
    Step 5: Is fat or water white? MRI usually shows fat and water as white.
    In MRI scans the fat underneath the skin or reservoirs of water in the body can be either white or dark in appearance, depending on the pulse sequence. For CT however, fat and water are almost never white. Look for fat just underneath the skin in almost any part of the body. Structures that contained mostly water include the cerebrospinal fluid around the spinal cord in the spinal canal and around the brain, the vitreous humor inside the eyeballs, bile within the gallbladder and biliary tree of the liver, urine within the bladder and collecting systems of the kidneys, and in some abnormal states such as pleural fluid in the thorax and ascites in the abdomen. It should be noted that water-containing structures can be made to look white on CT scans by intentional mixing of contrast in the structures in highly specialized scans, such as in a CT urogram or CT myelogram. But in general if either fat or fluid in the body looks white, you are dealing with an MRI.
     
    Step 6: Is the bone black? CT never shows bones as black.
     
    If you can see bony structures on your scan and they are black or dark gray in coloration, you are dealing with an MRI. On CT scans the bone is always white because the calcium blocks (attenuates) the x-ray photons. The calcium does not emit a signal in MRI scans, and thus appears dark. Bone marrow can be made to also appear dark on certain MRI pulse sequences, such as STIR sequences. If your scan shows dark bones and bone marrow, you are dealing with an MRI.
     
    A question I am often asked is "If bones are white on CT scans, if I see white bones can I assume it is a CT?" Unfortunately not. The calcium in bones does not emit signal on MRI and thus appears black. However, many bones also contain bone marrow which has a great deal of fat. Certain MRI sequences like T1 and T2 depict fat as bright white, and thus bone marrow-containing bone will look white on the scans. An expert can look carefully at the bone and discriminate between the calcium containing cortical bone and fat containing medullary bone, but this is beyond what a layperson will notice without specialized training.
    Self Test: Examples of CT and MRI Scans
    Here are some examples for you to test your newfound knowledge.
    Example 1

    Figure 5A: A mystery scan of the brain
     
    Look at the scan above. Can you see the table that the patient is laying on? No, so this is probably an MRI. Let's not be hasty in our judgment and find further evidence to confirm our suspicion. Is the cerebrospinal fluid surrounding the brain and in the ventricles of the brain white? No, on this scan the CSF appears black. Both CT scans and MRIs can have dark appearing CSF, so this doesn't help us. Is the skin and thin layer of subcutaneous fat on the scalp white? Yes it is. That means this is an MRI. Well, if this is an MRI than the bones of the skull, the calvarium, should be dark, right? Yes, and indeed the calvarium is as shown in Figure 5B. You can see the black egg shaped oval around the brain, which is the calcium containing skull. The only portion of the skull that is white is in the frontal area where fat containing bone marrow is present between two thin layers of calcium containing bony cortex. This is an MRI.
     

    Figure 5B: The mystery scan is a T1 spoiled gradient echo MRI image of the brain. Incidentally this person has a brain tumor involving the left frontal lobe.
     
    Example 2

    Figure 6A: Another mystery scan of the brain
     
    Look at the scan above. Let's go through our process to determine if this is a CT or MRI. First of all, can you see the table the patient is lying on or brace? Yes you can, there is a U-shaped brace keeping the head in position for the scan. We can conclude that this is a CT scan. Let's investigate further to confirm our conclusion. Is fat or water white? If either is white, then this is an MRI. In this scan we can see both fat underneath the skin of the cheeks which appears dark gray to black. Additionally, the material in the eyeball is a dark gray, immediately behind the relatively white appearing lenses of the eye. Finally, the cerebrospinal fluid surrounding the brainstem appears gray. This is not clearly an MRI, which further confirms our suspicion that it is a CT. If indeed this is a CT, then the bones of the skull should be white, and indeed they are. You can see the bright white shaped skull surrounding the brain. You can even see part of the cheekbones, the zygomatic arch, extending forward just outside the eyes. This is a CT scan.
     

    Figure 6B: The mystery scan is a CT brain without IV contrast.
     
    Example 3

    Figure 7A: A mystery scan of the abdomen
     
    In this example we see an image through the upper abdomen depicting multiple intra-abdominal organs. Let's use our methodology to try and figure out what kind of scan this is. First of all, can you see the table that the patient is laying on? Yes you can. That means we are dealing with the CT. Let's go ahead and look for some additional evidence to confirm our suspicion. Do the bones appear white? Yes they do. You can see the white colored thoracic vertebrae in the center of the image, and multiple ribs are present, also white. If this is indeed a CT scan than any water-containing structures should not be white, and indeed they are not. In this image there are three water-containing structures. The spinal canal contains cerebrospinal fluid (CSF). The pickle shaped gallbladder can be seen just underneath the liver. Also, this patient has a large (and benign) left kidney cyst. All of these structures appear a dark gray. Also, the fat underneath the skin is a dark gray color. This is not in MRI. It is a CT.
     

    Figure 7B: The mystery scan is a CT of the abdomen with IV contrast
     
    Example 4

    Figure 8A: A mystery scan of the left thigh
     
    Identifying this scan is challenging. Let's first look for the presence of the table. We don't see one but the image may have been trimmed to exclude it, or the image area may just not be big enough to see the table. We can't be sure a table is in present but just outside the image. Is the fat under the skin or any fluid-filled structures white? If so, this would indicate it is an MRI. The large white colored structure in the middle of the picture is a tumor. The fat underneath the skin is not white, it is dark gray in color. Also, the picture is through the mid thigh and there are no normal water containing structures in this area, so we can't use this to help us. Well, if this is a CT scan than the bone should be white. Is it? The answer is no. We can see a dark donut-shaped structure just to the right of the large white tumor. This is the femur bone, the major bone of the thigh and it is black. This cannot be a CT. It must be an MRI. This example is tricky because a fat suppression pulse sequence was used to turn the normally white colored fat a dark gray. Additionally no normal water containing structures are present on this image. The large tumor in the mid thigh is lighting up like a lightbulb and can be confusing and distracting. But, the presence of black colored bone is a dead giveaway. 
     

    Figure 8B: The mystery scan is a contrast-enhanced T2 fat-suppressed MRI
     
    Conclusion: Now You Can Determine is a Scan is CT or MRI
    This tutorial outlines a simple process that anybody can use to identify whether a scan is a CT or MRI. The democratiz3D service on this website can be used to convert any CT scan into a 3D printable bone model. Soon, a feature will be added that will allow you to convert a brain MRI into a 3D printable model. Additional features will be forthcoming. The service is free and easy to use, but you do need to tell it what kind of scan your uploading. Hopefully this tutorial will help you identify your scan.
     
    If you'd like to learn more about the democratiz3D service click here. Thank you very much and I hope you found this tutorial to be helpful.
     
    Nothing in this article should be considered medical advice. If you have a medical question, ask your doctor.
     
  10. Like
    Dr. Mike got a reaction from Kendell for a blog entry, 3D Printing of Bones from CT Scans: A Tutorial on Quickly Correcting Extensive Mesh Errors using Blender and MeshMixer   
    Hello and welcome back. Once again, I am Dr. Mike, board-certified radiologist and 3D printing enthusiast. Today I'm going to show you how to correct severe mesh defects in a bone model generated from a CT scan. This will be in preparation for 3D printing. I'll be using the free software programs Blender and Meshmixer.
    In my last medical 3d printing video tutorial, I showed you how to remove extraneous mesh within the medullary cavity of a bone. That technique is best used when mesh defects are limited. In instances where mesh defects in a bony model are severe and extensive, a different approach is needed. In this video, I'll show you how to correct extensive mesh errors in bony anatomical models using Blender and Meshmixer. This assumes that you know how to generate a basic STL file from a CT scan. There are a variety of commercial and freeware products that allow you to do this, on a variety of platforms. If you don't yet know how to do this, stay tuned, as I have a series of tutorials planned which will show you how to do this on a variety of operating systems and budgets.
    If you wish to follow along with this tutorial, you can download the free tutorial file pack by clicking this link. This is highly recommended, as the files allow you to follow along with the tutorial, which will make learning easier. Included is the STL file used in this tutorial. Also, a powerful Blender script is included which will enable you to easily and efficiently prepare your own bone models for 3D printing. It's a real timesaver. If you haven't registered at Embodi3D.com, registration is free and only takes a moment.
    DOWNLOAD THE ACCOMPANYING FILE PACK. CLICK HERE.
    You can watch the video tutorial for a quick overview, or read this article for a detailed description.
    Initial analysis using Meshmixer
    Let's take a look at an STL file of a talus fracture in the ankle. This 3D model is from a real patient who suffered a fracture of the talus. The talus is the bone in the ankle that the tibia, or shinbone, sits on. This STL file is included in the file pack. Let's open this file in Meshmixer (Figure 1). Meshmixer is free software published by Autodesk, a leading maker of engineering software. If you don't have Meshmixer, you can go to Meshmixer.com and download it for free.

    Figure 1
    Once you have the file open in Meshmixer, click on the Analysis button and select Inspector. The inspector shows all the errors in this mesh. Blue parts represent holes in the mesh. Red parts show areas where the mesh is non-manifold. Magenta parts show disconnected components. As you can see, there are a lot of problems with this mesh, and it is not suitable for 3D printing in its current state (Figure 2).

    Figure 2
    Meshmixer has a feature to automatically repair these mesh defects. However, there are so many problems with this mesh that the auto repair function fails. Click on the Auto Repair All button. Meshmixer has tried to repair these mesh defects, and has successfully reduced the number of defects. However, it is also introduced gaping holes in the model. Entire bones are missing (Figure 3). This clearly isn't the desired outcome.

    Figure 3
    Opening the STL file in Blender
    The solution to this problem can be found with Blender. Blender is a free, open-source software package that is primarily designed for animation. It is so feature-rich however, that it can be used for a variety of different purposes, and increasingly is being used for tasks related to 3D printing. If you don't have Blender, you can download it from blender.org. At the time of this writing, the current version is 2.73 a.
    Open up Blender. Go ahead and delete the default cube shown in the middle of the screen (Figure 4) by right clicking it and hitting the "X" key followed by the "D" key. If you are new to Blender, you'll soon learn that much of what you can do with Blender can be done with keyboard shortcuts. This can be daunting to learn for beginners, but makes use of Blender very efficient for heavy users.

    Figure 4
    Next open the STL file in Blender. Go to the File menu in the upper left, select Import, and select "Stl (.stl)." Then, navigate to the folder for the tutorial files and select the "ankle - talus fracture.stl" file. You probably don't see anything, as is shown in Figure 5. To understand how this happens, you need to know a little bit about how Blender measures distances. Blender uses an arbitrary measure of distance called a "blender unit." One blender unit is equivalent to one of the little squares seen in the viewport. However, in real life distances are measured in real units, such as feet, inches, centimeters, and millimeters. Most STL files that are generated from medical imaging data have default unit of measurement of millimeters. When Blender imports the file it converts the millimeter units to blender units. Since our imported model is the size of human foot, measuring 240 mm or so, the model will be 240 blender units, or 240 of those little squares, in length. We can't see it because the model is too big! Our viewport is zoomed into much! Zoom out using the mouse wheel way, way back until you can see the model as shown in Figure 6.

    Figure 5: Where is the model?

    Figure 6: There it is!
    Correcting the Object Origin
    You will notice that the origin of the ankle object, as shown by the red blue and green axes (Figure 6), is actually outside of object itself. Left uncorrected, this can be a really annoying issue. When you rotate or pan around the object, you will rotate or pan around these three axes, instead of the ankle object itself. Fortunately, correcting this takes only a moment. In the lower left-hand part of the window select the Object menu. Be sure that you have the ankle object selected first. Then choose Transform, Geometry to Origin. The ankle object is then moved to the red blue and green axes. With the object origin now in the center of the mesh, the mesh will be much easier to work with.

    Figure 7: The ankle mesh and object origin are now aligned.
    Inspect the ankle mesh
    If you look closely at the ankle mesh you can see immediately that it has a lot of problems. In the solid shader mode, the bones look very faceted. The polygons are large, giving the bones a unnatural appearance (Figure 8). Don't worry, will fix this. If you turn on wireframe mode by hitting the "Z" key you can see that there is a lot of extraneous mesh within the bones that represents unwanted mesh from the medullary cavities of these bones (Figure 9). Furthermore, if you check for non-manifold mesh by holding control-shift-alt-M, you'll see that there are innumerable non-manifold mesh defects (Figure 10).

    Figure 8: Note the very faceted appearance of the bones.

    Figure 9: There is a significant amount of unneeded and extraneous mesh, particularly within the medullary cavities of the bones.

    Figure 10: Non-manifold mesh defects.
    If you are unfamiliar with the term "non-manifold," let me take a moment to explain. A mesh is simply a surface. It is infinitely thin. If the mesh is continuous and unbroken, and has a contained volume within it, then the mesh can be considered to represent something solid. In this case, the mesh surface represents the interface between the inside of the object and the outside of the object, such as the sphere shown in Figure 11. An object like this is considered to be "manifold," or watertight. It represents a solid that can really exist in the physical world, and can thus be 3D printed.

    Figure 11
    If however, I cut a hole in the sphere, as shown in Figure 12, then there is a gap in the mesh. A 3D printer won't know what to do with this. Is this supposed to be solid like a ball, or hollow like a cup? If it is supposed to be like a cup, how thick are the walls supposed to be? The walls in this mesh are infinitesimally thin, so what is the correct thickness? This mesh is not watertight - that is, should water be placed in the structure it would leak out. The mesh is non-manifold. It cannot be 3D printed. If we use the control-shift-alt-M sequence to highlight non-manifold mesh, as shown in Figure 13, we can see that Blender correctly identifies the edge of the hole as having non-manifold mesh.

    Figure 12

    Figure 13
    Closing major holes manually in Blender
    In this particular mesh, there are many, many small mesh errors and two very large ones. The distal tibia and fibula bones have been cut off by the CT scanner, leaving gaping holes in the mesh as shown in Figure 14. Fixing these manually will only take a moment and make things easier down the road, so let's take care of that now. Enter Edit mode by hitting the Tab key, or clicking it in the Mode menu. If you hit control-shift-alt-M to select non-manifold edges, you can clearly see that these bone cuts are a problem as shown in Figure 15.

    Figure 14

    Figure 15
    Go to Vertex selection mode by clicking the vertex button or hitting control-tab-1 on the keyboard as shown in Figure 16. Select one of the vertices from the medullary portion of the tibia bone as shown in Figure 17. This mesh represents the medullary cavity of the tibia bone, and is not connected to the rest of the mesh. Hit control-L to select all contiguous vertices (Figure 18). All the unwanted medullary cavity mesh should now be highlighted. Delete this by hitting the "X" key followed by the "V" key, or by hitting the delete and selecting "vertices." There is another small bit of medullary cavity mesh at the edge of the tibia cut. Perform the same routine and delete this as well.

    Figure 16

    Figure 17

    Figure 18
    Next we will direct our attention to the unwanted medullary mesh of the thinner fibula bone. Click on a vertex in the fibula medullary mesh and hit control L. You will note that the entire mesh is highlighted as shown in Figure 19. This indicates that the medullary mesh is connected to the rest of the mesh in some way. We don't need to manually delete all of the medullary mesh. We just need to get it away from the edge where we will create a new face to close the bone edges. Go to Edge selection mode by hitting control-tab-2 or clicking the edge selection button as shown in Figure 20. Hit the "A" key to unselect everything. Then, click on a single edge along the unwanted medullary mesh, as shown in Figure 21.

    Figure 19

    Figure 20

    Figure 21
    Next we will by holding down the alt key and right clicking on the edge again. Blender should select the loop around the entire edge as shown in Figure 22. We will now expand the selection by holding down the control tab and hitting the plus key on the number pad. Hit the plus key three times. Your selection should now look like that in Figure 23. Delete the highlighted mesh by hitting the "X" and "V" keys, or hitting the delete key and selecting vertices.

    Figure 22

    Figure 23
    Next we are going to close the holes by holding down the alt key and right clicking along the edge of the cut line of the fibula. An entire loop should be selected as shown in Figure 24. Create a face by hitting the "F" key. Convert to triangles by hitting Control-T. The end of the fibula should be closed, as shown in Figure 25. Repeat the same for the open edge of the tibia bone. Afterwards the mesh should look as it does and Figure 26.

    Figure 24

    Figure 25

    Figure 26
    Creating a Shell of the model using the Shrinkwrap and Remesh modifiers in Blender
    So how will it ever be possible to correct the hundreds and hundreds of mesh errors in the ankle model? This is the million-dollar question. A mesh of this complexity often cannot be fixed using automated mesh correction software, as we saw with Meshmixer. Correcting this many errors manually is a time-consuming and tedious process. I've spent hundreds of hours correcting mesh errors like this one by one. But, after years of creating 3D printable anatomical models, I've developed a technique to fix these mesh errors in only a few minutes.
    The secret is this: You don't fix the mesh errors. Leave them alone. You create a new mesh to replace them!
    Let's start by creating a sphere. If you are in Edit mode, exit that by hitting the Tab key. If you are still in wireframe viewport mode, hit the "Z" key to return to solid viewport shading. In the lower left-hand side of the window, hit the Add menu. Select Mesh, UV sphere and add a sphere. An "Add UV Sphere" panel will show up on the left side of your screen as shown in Figure 27. We want the sphere to have lots of detail. Under Segments enter 256. Under Rings, enter 128. The default size of the sphere is only one blender unit (1 mm) in size. This is too small, we want the thing to be huge. Enter 1000 for size. At this point you should have a very large sphere surrounding your entire scene. Believe it or not, this sphere will eventually be your new ankle object. Let's go ahead and rename it "Ankle skin" as shown in Figure 29.

    Figure 27: Add a UV sphere

    Figure 28: Configure the sphere. Segments 256, rings 128, size 1000

    Figure 29: Rename the sphere to "Ankle skin"
    Applying the Shrinkwrap Modifier
    Select the "Ankle skin" object. Click on the Modifiers tab, it looks like a small wrench (Figure 30). From the Ad Modifier drop-down menu, select the Shrinkwrap item. Specify the Ankle object as "the target. Set off set to 0.5. Check the" Keep Above Surface" box. Your sphere will have shrunken down to envelop the ankle, as shown in Figure 30. Apply the modifier by hitting the "Apply" button. At this point you're thinking that your Ankle skin object hardly looks like an ankle, and you're right. If you try to apply the shrinkwrap modifier again, you won't get any change in the mesh. Blender has shrunken the sphere as best it can given the limited geometry of the sphere. To go further we need to change the geometry a bit, which is where the Remesh modifier comes in.

    Figure 30: The Shrinkwrap modifier
    Applying the Remesh Modifier
    Next go to Add Modifier again, and select Remesh. Set Mode to Smooth, Octree Depth = 8, and uncheck Remove Disconnected Pieces. By now you should have something that looks like Figure 31. Apply the modifier by clicking the Apply button.

    Figure 31: The Remesh modifier
    Apply the Shrinkwrap Modifier again
    Apply the shrinkwrap modifier again, using the same parameters as before. Your Ankle skin object should look like Figure 32. Now we are getting somewhere! There is still a long way to go, but the mesh somewhat resembles the bones of the foot. By repeatedly applying the Shrinkwrap and Remesh modifiers the Ankle skin object, which was originally a sphere, will slowly approximate the surface of the error-filled original ankle mesh. Because of the original skin was a sphere, and hence manifold, as it is shrink-wrapped around the ankle mesh it will preserve (for the most part) it's mesh integrity. There will be no unnecessary internal geometry. Any holes or other defects in the original mesh will be covered. Unfortunately, repeatedly applying the shrinkwrap and remesh modifier again and again is somewhat tedious (although not as tedious as manually correcting all the errors in the original mesh). Fortunately, we can automate this process using Python scripting. This allows us to create a new mesh in a matter of minutes.

    Figure 32
    Automating the Shrinkwrap Process using Python Scripting
    For those of you less familiar with Blender's more advanced features, you may be surprised to learn that it is fully scriptable. That means that you can program it to perform tasks repeatedly using a Python script. In this case we want to repeatedly execute shrinkwrap and remesh modifiers on our ankle skin object. With each iteration the skin will more closely approximate the surface of the original mesh. If you are familiar with Python scripting, you can write a script yourself to call the necessary modifiers and specify the necessary variables. To make things easier for you, I have written a Python script for you. It is included in the free tutorial file pack.
    Change the bottom window to the text editor. View button in the bottom left-hand corner as shown in Figure 33. Select Text Editor. Click on the "Open" button and navigate to the folder with the tutorial file pack files as shown in Figure 34. Double-click on the "shrinkwrap loop.txt" file as shown in Figure 35.

    Figure 33: Select the text editor

    Figure 34: Click on the Open button

    Figure 35: Open the "shrinkwrap loop.txt" file
    The script file should now open in the text editor window. Adjust the target_object variable to be the target you want your skin wrapped around, in this case the "Ankle - Talus Fracture" object. Leave the shrinkwrap_offset variable at 0.5 for now. You can specify how many shrinkwrap-remesh iterations you want to run. For now leave it at 20. Click the "Run Script" button as shown in Figure 36. The script will now run, and it will apply the shrinkwrap-remesh modifiers 20 times. On my machine it takes about one minute for the script to execute.

    Figure 36
    At this point you'll notice that the ankle skin object very closely approximates the original ankle object, as shown in Figure 37. Run the script again using the same settings. At this point the mesh is really looking pretty good. Let's run the script a final time with the smaller offset to more closely approximate the real bones. Set the shrinkwrap_offset variable to 0.3 and run the script again reducing iterations to 10. After completion the mesh should appear as it does in Figure 38. If you compare our new skin mesh as shown in Figure 39 (left) to the original ankle object in Figure 39 (right) you can see that our new skin is actually much more realistic than the original mesh. The highly faceted appearance of the original mesh has been replaced by a smoothed appearance of our shrink-wrapped skin. Furthermore, whereas the original mesh actually had separate bones that were disconnected, the new, shrink-wrapped mesh is a single interconnected object. From a 3D printing standpoint this is much better as the ankle bones will print together as a single unit

    Figure 37

    Figure 38

    Figure 39: Comparison of original plus new shrink-wrapped mesh.
    Finalizing the Ankle Model for 3D printing using Meshmixer.
    Select the new ankle object. Export the object to the STL file format. From the file menu select Export and then "Stl (.stl)." Let's call the file "ankle corrected.STL." Open the new STL file in Meshmixer. You will notice that Meshmixer immediately identifies some mesh errors as shown in Figure 40. This is because the Remesh modifier in Blender occasionally introduces non-manifold mesh defects. You will note however that the number of defect is significantly less than our original model which was shown in Figure 1. With this smaller number of errors, Meshmixer can fix them automatically. Go to the Analysis button and select Inspector. Meshmixer will highlight the individual mesh defects, as shown in Figure 41. Click on the "Auto Repair All" button. Meshmixer will then automatically repair the mesh defects. The result is shown in Figure 42.

    Figure 40

    Figure 41: Meshmixer inspector

    Figure 42: Corrected mesh
    The mesh looks great, and is ready for 3D printing! Export the STL file by going to the File menu in Meshmixer and selecting Export. Save the file as "ankle final result.STL".
    Please share with the community.
    If you have found this tutorial helpful and are actively creating 3D printable anatomic models, please consider sharing your work with the Embodi3D community. You can share your models in the File Vault. If you have comments or advice, you can share your expertise in the Forums. If you are interested in blogging about your adventures in medical 3D printing, contact me or one of the administrators and we can set up blogging on your Embodi3D user account. If you wish to hire someone to help you with your anatomical 3D printing project, you can place an ad for free in the Services Needed Forum, If you are doing your own anatomical 3D printing and are willing to help others, list your services for free in the Services Offered Forum.
    This is a community. We are all helping each other. Please consider giving back if you can.
    Have fun 3D printing!
  11. Like
    Dr. Mike got a reaction from Kendell for a blog entry, How to create an NRRD file from a DICOM Medical Imaging Data Set   
    NRRD is a file format for storing and visualizing medical image data. Its main benefit over DICOM, the standard file format for medical imaging, is that NRRD files are anonymized and contain no sensitive patient information. Furthermore NRRD files can store a medical scan in a single file, whereas DICOM data sets are usually comprised of a directory or directories that contain dozens if not hundreds of individual files. NRRD is thus a good file for transferring medical scan data while protecting patient privacy. This tutorial will teach you how to create an NRRD file from a DICOM data set generated from a medical scan, such as a CT, MRI, ultrasound, or x-rays.
     
    To complete this tutorial you will need a CD or DVD with your medical imaging scan, or a downloaded DICOM data set from one of many online repositories. If you had a medical scan at a hospital or clinic you can usually obtain a CD or DVD from the radiology department after signing a waiver and paying a small copying fee.
     
    Step 1: Download Slicer
     
    Slicer is a free software program for medical imaging. It can be downloaded from the www.slicer.org. Once on the Slicer homepage, click on the Download link as shown in Figure 1.
     

    Figure 1
     
    Slicer is available for Windows, Mac, and Linux. Choose your operating system and download the latest stable release as shown in Figure 2.
     

    Figure 2: Download Slicer
     
    Step 2: Copy the DICOM files into Slicer.
     
    Insert your CD or DVD containing your medical scan data into your CD or DVD drive, or open the folder containing your DICOM files if you have a downloaded data set. If you navigate into the folder directory, you will notice that there are usually multiple DICOM files in one or more directories, as shown in Figure 3. Navigate to the highest level folder containing all the DICOM files.

    Figure 3: There are many DICOM files in a study
     
    Open Slicer. The welcome screen will show, as demonstrated in Figure 4. Left click on the folder that contains the DICOM files and drop it onto the Welcome panel in Slicer. Slicer will ask you if you want to load the DICOM files into the DICOM database, as shown in Figure 5. Click OK Slicer will then ask you if you want to copy the files or merely add links. Click Copy as shown in Figure 6.

    Figure 4: Drag and drop the DICOM folder onto the Slicer Welcome window.
     

    Figures 5 and 6
     
    After working for a minute or two, Slicer will tell you that the DICOM import was successful, as shown in Figure 7. Click OK

    Figure 7
     
    Step 3: Open the Medical Scan in Slicer.
     
    At this point you should see a window called the DICOM Browser, as shown in Figure 8. The browser has three panels, which show the patient information, study information, and the individual series within each study. If you close the DICOM Browser and need to open it again, you can do so under the Modules menu, as shown in Figure 9.

    Figure 8: DICOM Browser
     

    Figure 9: Finding the DICOM browser
     
    Each series in a medical imaging scan is comprised of a stack of images that together make a volume. This volume can be used to make the NRRD file. Modern CT and MRI scans typically have multiple series and different orientations that were collected using different techniques. These multiple views of the same structures allow the doctors reading the scan to have the best chance of making the correct diagnosis. A detailed explanation of the different types of CT and MRI series is beyond the scope of this article, but will be covered in a future tutorial.
     
    Click on the single patient, study, and a series of interest. Click the Load button as shown in Figure 8. The series will then begin to load as shown in Figure 10.

    Figure 10: The study is loading
     
    Step 4: Save the Imaging Data in NRRD Format
    Once the series loads you will see the imaging data displayed in the Slicer windows. Click the Save button on the upper left-hand corner, as shown in Figure 11.

    Figure 11: Click the Save button
     
    The Save Scene dialog box will then appear. Two or more rows may be shown. Put a checkmark next to the row that has a name that ends in ".nrrd". Uncheck all other rows. Click the directory button for the nrrd file and specify the directory to save the file into. Then click the save button, as shown in Figure 12.

    Figure 12: Check the NRRD file and specify save directory.
     
    The NRRD file will now be saved in the directory you specified!
     
  12. Like
    Dr. Mike reacted to mikefazz for a blog entry, Segmentation of a foot MRI scan   
    So I have seen some questions here on embodi3D asking how to work with MRI data.  I believe the main issue to be with attempting to segment the data using a threshold method.  The democratiz3D feature of the website simplifies the segmentation process but as far as I can tell relies on thresholding which can work somewhat well for CT scans but for MRI is almost certain to fail.  Using 3DSlicer I show the advantage of using a region growing method (FastGrowCut) vs threshold.
     
    The scan I am using is of a middle aged woman's foot available here

     
    The scan was optimized for segmenting bone and was performed on a 1.5T scanner.  While a patient doesn't really have control of scan settings if you are a physician or researcher who does; picking the right settings is critical.  Some of these different settings can be found on one of Dr. Mike's blog entries.
     
    For comparison purposes I first showed the kind of results achievable when segmenting an MRI using thresholds.

     
    With the goal of separating the bones out the result is obviously pretty worthless.  To get the bones out of that resultant clump would take a ridiculous amount of effort in blender or similar software:

     
    If you read a previous blog entry of mine on using a region growing method I really don't like using thresholding for segmenting anatomy.  So once again using a region growing method (FastGrowCut in this case) allows decent results even from an MRI scan.
     

     
    Now this was a relatively quick and rough segmentation of just the hindfoot but already it is much closer to having bones that could be printed.  A further step of label map smoothing can further improve the rough results.

     
    The above shows just the calcaneous volume smoothed with its associated surface generated.  Now I had done a more proper segmentation of this foot in the past where I spent more time to get the below result

     
    If the volume above is smoothed (in my case I used some of my matlab code) I can get the below result.

     
    Which looks much better.  Segmenting a CT scan will still give better results for bone as the cortical bone doesn't show up well in MRI's (why the metatarsals and phalanges get a bit skinny), but CT scans are not always an option.
     
    So if you have been trying to segment an MRI scan and only get a messy clump I would encourage you to try a method a bit more modern than thresholding.  However, keep in mind there are limits to what can be done with bad data.  If the image is really noisy, has large voxels, or is optimized for the wrong type of anatomy there may be no way to get the results you want.
  13. Like
    Dr. Mike reacted to mikefazz for a blog entry, 3D Printed Wrist Brace   
    So I began to develop some pain in my right wrist which was later diagnosed as tendinitis. At the same time I had been looking at the CT scan of my abdomen and noticed they also captured my right hand as it was resting on my stomach during the scan (I had injured my right shoulder again).
     
     
    I recalled a concept project a while back I had seen: the CORTEX brace. It presented the idea of replacing the typical plaster cast with a 3D printed one which would prevent the issues of sweating and itchiness… as well as be much more stylish (though not allowing people to sign your cast).
    I had wanted to apply this to prosthesis sockets initially but never got past the idea stage. Looking around for how to create the ‘webbing’ style I found that meshmixer had the necessary capabilities. So I now had all the tools needed to make my own brace to partially immobilize my wrist.
     
    Once the surface model is created and loaded into meshmixer the first step is to cut off anatomy that you don't want in the model using 'plane cut'.


     
    Once the general shape of the brace is created the next step is to consider how the brace will be taken on and off.  For my design I wanted to have one piece that is flexible enough to slide my wrist in.  To create the 'slot' I found that I did a boolean in blender as meshmixer would crash when I tried to create the slot.
     

     
    With the brace model and slot in place the next step was to offset the surface since creating the voroni mesh would generate the tubes on both sides of the surface.  This is done back in meshmixer and is fairly computationally intensive so partially reducing the mesh density first is a good idea.
     

     
    The next step is to further decimate the mesh to get the desired voroni mesh pattern.  This takes a bit of playing around to get the desired style.  Too dense and the resulting web structure will not have many openings which will be stronger but not as breathable.  Too rough and the model may not conform to the surface well causing pressure points.
     

     
    The final step is to take the reduced mesh and web like structure using the 'make pattern' feature within meshmixer.  There are various settings to be applied within this feature but setting 'Dual Edges' then adjusting the pipe size to double your offset will result in the inner edge of the webbing to just touch the skin of the initial model.
     

     
    Having never made a brace/cast before it took me a few iterations to get a design which I could easily don and doff (put on and take off). I also found that I could make a brace that held my wrist very rigidly but would be too restrictive.
     

     
    Also material selection became important.  Initially I used ABS which is more flexible than PLA and I had it in a nice pink skin color. It turned out to be too rigid for the style I was designing.  I found PETT (taulman t-glass) to work well as it had a lower modulus of elasticity meaning it was more flexible than ABS.


     
    After using the brace on and off for a few weeks I have found that it fits well and is surprisingly comfortable. I have taken a shower with it on as well as slept with it on.  It doesn’t seem to smell as bad as the cheap and common cloth type braces.  The main downsides have been taking it on and off is a bit challenging still and it is more restrictive of my motion as it behaves somewhere between a brace and a cast. There is definitely a great deal of potential for this type of cast though widespread adoption would require further technical development to simplify the process.
  14. Like
    Dr. Mike got a reaction from sebastien mockels for a blog entry, Creating 3D Printable Medical Models and STL Files for Free: Online Services vs. Desktop Software - Slicer and Meshmixer   
    Note: This tutorial accompanies a workshop I presented at the 2016 Radiological Society of North America (RSNA) meeting. The workflow and techniques presented in this tutorial and the conference workshop are identical.
     

     
    In this tutorial we will be using two different ways to create a 3-D printable medical model of a head and neck which will be derived from a real contrast-enhanced CT scan. The model will show detailed anatomy of the bones, as well as the veins and arteries. We will independently create this model using two separate methods. First, we will automatically generate the model using the free online service embodi3D.com. Next, we will create the same file using free desktop software programs 3D Slicer and Meshmixer.
     
    If you haven't already, please download the associated file pack which contains the files you'll need to follow along with this tutorial. Following along with the actual files used here will make learning these techniques much easier. The file pack is free. You need to be logged into your embodi3D account to download, but registration is also free and only takes a minute. Also, you'll need an embodi3D.com account in order to use the online service. Registration is worth it, so if you haven't already go ahead and register now.
     
    >> DOWNLOAD THE FILE PACK NOW <<
     
    Online Service: embodi3D.com
     
     
    Step 1: Go to the embodi3D.com website and click on the democratiz3D menu item in the naw bar. Click on the "Launch democratizD" link, as shown in Figure 1.
     

    Figure 1: Opening the free online 3D model making service service democratiz3D.
     
    Step 2: Now you have to upload your imaging file. Drag and drop the file MANIX Angio CT.nrrd from the File Pack, as shown in Figure 2. This contains the CT scan of the head and neck in NRRD file format. If you are using a file other NRRD that provided by the file pack, please be aware the file must contain a CT scan (NOT MRI!) and the file must be in NRRD format. If you don't know how to create an NRRD file, here is a simple tutorial that explains how.
     

    Figure 2: Dragging and dropping the NRRD file to start uploading.
     
    Step 3: Type in basic information on the file being uploaded, including File name, file description, and whether you want to share the file or keep it private. Bear in mind that this information pertains to the uploaded file, not the file that will be generated by the service.

    Step 4: Type in basic parameters for file processing. Turn on the processing slider. Here you will enter in basic information about how you would like the file to be processed. Under Operation, select CT NRRD to Bone STL Detailed, as shown in Figure 3. This will convert a CT scan in NRRD format to a bone STL with high detail. You also have the option to create muscle and skin STL files. The standard operation, CT NRRD to Bone STL sacrifices some detail for a smoother output model. Leave the default threshold at 150.
     

    Figure 3: Selecting an operation for file conversion.
     
    Next, choose the quality of your output file. Low-quality files process quickly and are appropriate for structures with simple geometry. High quality files take longer to process and are appropriate for very complex geometry. The geometry of our model will be quite complex, so choose high quality. This may take a long time to process however, sometimes up to 40 minutes. If you don't wish to wait so long, you can choose medium quality, as shown in Figure 4, and have a pretty decent output file in about 12 minutes or so.
     
     

    Figure 4: Choosing a quality setting.
     
    Finally, specify whether you want your processed file to be shared with the community (encouraged) or private and accessible only to you. If you do decide to share you will need to fill out a few items, such as which CreativeCommons license to share under. If you're not sure, the defaults are appropriate for most people. If you do decide to share thanks very much! The 3D printing community thanks you!
     
    Click on the submit button and your file will be submitted for processing! Now all you have to do is wait. The service will do all the work for you!
     
    Step 5: Download your file. In 5 to 40 minutes you should receive an email indicating that your file is done and is ready for download. Follow the link in the email message or, if you are already on the embodi3D.com website, click on your profile to view your latest activity, including files belonging to you. Open the download page for your file and click on the "Download this file" button to download your newly created STL file!
     

    Figure 5: Downloading your newly completed STL file.
     
     
    Desktop software
    If you haven't already, download 3D Slicer and Meshmixer. Both of these programs are available on Macintosh and Windows platforms.
     
    Step 1: Create an STL file with 3D Slicer. Open 3D Slicer. Drag and drop the file MANIX Angio CT.nrrd from the file pack onto the 3D Slicer window. This should load the file into 3D Slicer, as shown in Figure 6. When Slicer asks you to confirm whether you want to add the file, click OK.
     

    Figure 6: Opening the NRRD file in 3D Slicer using drag-and-drop.
     
    Step 2: Convert the CT scan into an STL file. From within Slicer, open the Modules menu item and choose All Modules, Grayscale Model Maker, as shown in Figure 7.
     

    Figure 7: Opening the Grayscale Model Maker module.
     
    Next, enter the conversion parameters for Grayscale Model Maker in the parameters window on the left. Under Input Volume select MANIX Angio CT. Under Output Geometry choose "Create new model." Slicer will create a new model with the default name such as "Output Geometry. If you wish to rename this to something more descriptive, choose Rename current model under the same menu. For this tutorial I am calling the model "RSNA model."
     
    For Threshold, set the value to 150. Under Decimate, set the value to 0.75. Double check your settings to make sure everything is correct. When everything is filled in correctly click the Apply button, as shown in Figure 8. Slicer will process for about a minute.
     

    Figure 8: Filling in the Grayscale Model Maker parameters.
     
    Step 3: Save the new model to STL file format. Now it is time to create an STL file from our digital model. Click on the Save button on the upper left-hand corner of the Slicer window. The Save Scene pop-up window is now shown. Find the row that corresponds to the model name you have given the model. In my case it is called "RSNA model." Make sure that the checkbox next to this row is checked, and all other rows are unchecked. Next, under the File Format column make sure to specify STL. Finally, specify the directory that the new STL file is to be saved into. Double check everything. When you are ready, click Saved. This is all shown in Figure 9. Now that you've created an STL file, we need to postprocessing in Meshmixer.
     

    Figure 9: Saving your file to STL format.
     
    Step 4: Open Meshmixer, and drag-and-drop the newly created STL file onto the Meshmixer window to open it. Once the model opens, you will notice that there are many red dots scattered throughout the model. These represent errors in the mesh and need to be corrected, as shown in Figure 10.

    Figure 10: Errors in the mesh as shown in Meshmixer. Each red dot corresponds to an error.
     
    Step 5: Remove disconnected elements from the mesh. There are many disconnected elements in this model that we do not want in our final model. An example of unwanted mesh are the flat plates on either side of the head from the pillow that was used to secure the head during the CT scan. Let's get rid of this unwanted mesh.
     
    First use the select tool and place the cursor over the four head of the model and left click. The area under the cursor should turn orange, indicating that those polygons have been selected, as shown in Figure 11.
     

    Figure 11: Selecting a small zone on the forehead.
     
    Next, we are going to expand the selection to encompass all geometry that is attached to the area that we currently have selected. Go to the Modify menu item and select Expand to Connected. Alternatively, you can use the keyboard shortcut and select the E key. This operation is shown in Figure 12.
     

    Figure 12: Expanding the selection to all connected parts.
     
    You will notice that the right clavicle and right scapula have not been selected. This is because these parts are not directly connected to the rest of the skeleton, as shown in Figure 13. We wish to include these in our model, so using the select tool left click on each of these parts to highlight a small area. Then expand the selection to connected again by hitting the E key.
     

    Figure 13: The right clavicle and right scapula are not included in the selection because they are not connected to the rest of the skeleton. Individually select these parts and expand the selection again to include them.
     
    At this point you should have all the geometry we want included in the model selected in orange, as shown in Figure 14.
     

    Figure 14: All the desired geometry is selected in orange
     
    Next we are going to delete all the unwanted geometry that is currently unselected. To start this we will first invert the selection. Under the modify menu, select Invert. Alternatively, you can use the keyboard shortcut I, as shown in Figure 15.
     

    Figure 15: Inverting the selection.
     
    At this point only the undesired geometry should be highlighted in orange, as shown in Figure 16. This unwanted geometry cannot be deleted by going to the Edit menu and selecting Discard. Alternatively you can use the keyboard shortcut X.

    Figure 16: Only the unwanted geometry is highlighted in orange. This is ready to delete.
     
    Step 6: Correcting mesh errors using the Inspector tool. Meshmixer has a nice tool that will automatically fix many mesh errors. Click on the Analysis button and choose Inspector. Meshmixer will now identify all of the errors currently in the mesh. These are indicated by red, blue, and pink balls with lines pointing to the location of the error. As you can see from Figure 17, there are hundreds of errors still within our mesh. We can attempt to auto repair them by clicking on the Auto Repair All button. At the end of the operation most of the errors have been fixed, but if you remain. This can be seen in Figure 18.
     

    Figure 17: Errors in the mesh. Most of these can be corrected using the Inspector tool.
     

    Figure 18: Only a few errors remain after auto correction with the Inspector tool.
     
    Step 7: Correcting the remaining errors using the Remesh tool. Click on the select button to turn on the select tool. Expand the selection to connected parts by choosing Modify, Expand to Connected. The entire model should now be highlighted and origin color. Next under the edit menu choose Remesh, or use the R keyboard shortcut, as shown in Figure 19. This operation will take some time, six or eight minutes depending on the speed of your computer. What remesh does is it recalculates the surface topography of the model and replaces each of the surface triangles with new triangles that are more regular and uniform in appearance. Since our model has a considerable amount of surface area and polygons, the remesh operation takes some time. Remesh also has the ability to eliminate some geometric problems that can prevent all errors from being automatically fixed in Inspector.

    Figure 19: Using the Remesh tool.
     
    Step 8: Fixing the remaining errors using the Inspector tool. Once the remesh operation is completed we will go back and repeat Step 6 and run the Inspector tool again. Click on Analysis and choose Inspector. Inspector will highlight the errors. Currently there are only two, as shown in Figure 20. These two remaining errors can be easily auto repair using the Auto Repair All button. Go ahead and click on this.

    Figure 20: running the Inspector tool again.
     
    At this point the model is now completed and ready for 3D printing as shown in Figure 21. The mesh is error-free and ready to go! Congratulations!

    Figure 21: The final, error-free model ready for 3D printing.
    Conclusion
    Complex bone and vascular models, such as the head and neck model we created in this tutorial, can be created using either the free online service at embodi3D.com or using free desktop software. Each approach has its benefits. The online service is easier to use, faster, and produces high quality models with minimal user input. Additionally, multiple models can be processed simultaneously so it is possible to batch process multiple files at once. The desktop approach using 3D Slicer and Meshmixer requires more user input and thus more time, however the user has greater control over individual design decisions about the model. Both methods are viable for creating high quality 3D printable medical models.
     
    Thank you very much for reading this tutorial. Please share your medical 3D printing designs on the embodi3D.com website. Happy 3D printing!
  15. Like
    Dr. Mike got a reaction from TomP for a blog entry, A Ridiculously Easy Way to Convert CT Scans to 3D Printable Bone STL Models for Free in Minutes   
    Please note the democratiz3D service was previously named "Imag3D"
    In this tutorial you will learn how to quickly and easily make 3D printable bone models from medical CT scans using the free online service democratiz3D®. The method described here requires no prior knowledge of medical imaging or 3D printing software. Creation of your first model can be completed in as little as 10 minutes.
     
    You can download the files used in this tutorial by clicking on this link. You must have a free Embodi3D member account to do so. If you don't have an account, registration is free and takes a minute. It is worth the time to register so you can follow along with the tutorial and use the democratiz3D service.
     
    >> DOWNLOAD TUTORIAL FILES AND FOLLOW ALONG <<
    Both video and written tutorials are included in this page.
     
     
     
     
     
    Before we start you'll need to have a copy of a CT scan. If you are interested in 3D printing your own CT scan, you can go to the radiology department of the hospital or clinic that did the scan and ask for the scan to be put on a CD or DVD for you. Figures 1 and 2 show the radiology department at my hospital, called Image Management, and the CDs that they give out. Most radiology departments will have you sign a written release and give you a CD or DVD for free or with a small processing fee. If you are a doctor or other healthcare provider and want to 3D print a model for a patient, the radiology department can also help you. There are multiple online repositories of anonymized CT scans for research that are also available.
     
     

    Figure 1: The radiology department window at my hospital.
     

     
     
    Figure 2: An example of what a DVD containing a CT scan looks like. This looks like a standard CD or DVD.
     
     
     
    Step 1: Register for an Embodi3D account
     
    If you haven't already done so, you'll need to register for an embodi3d account. Registration is free and only takes a minute. Once you are registered you'll receive a confirmatory email that verifies you are the owner of the registered email account. Click the link in the email to activate your account. The democratiz3D service will use this email account to send you notifications when your files are ready for download.
     
    Step 2: Create an NRRD file with Slicer
    If you haven't already done so, go to slicer.org and download Slicer for your operating system. Slicer is a free software program for medical imaging research. It also has the ability to save medical imaging scans in a variety of formats, which is what we will use it for in this tutorial.
    Next, launch Slicer. Insert your CD or DVD containing the CT scan into your computer and open the CD with File Explorer or equivalent file browsing application for your operating system. You should find a folder that contains numerous DICOM files in it, as shown in Figure 3. Drag-and-drop the entire DICOM folder onto the Slicer welcome page, as shown in Figure 4. Click OK when asked to load the study into the DICOM database. Click Copy when asked if you want to copy the images into the local database directory.
     
     

    Figure 3: A typical DICOM data set contains numerous individual DICOM files.
     
     

    Figure 4: Dragging and dropping the DICOM folder onto the Slicer application. This will load the CT scan.
     
    Once Slicer has finished loading the study, click the save icon in the upper left-hand corner as shown in Figure 5. One of the files in the list will be of type NRRD. make sure that this file is checked and all other files are unchecked. click on the directory button for the NRRD file and select an appropriate directory to save the file. then click Save, as shown in Figure 6.
     
     

    Figure 5: The Save button
     

     
    Figure 6: The Save File box
     
    The NRRD file is much better for uploading then DICOM. Instead of having multiple files in a DICOM data set, the NRRD file encapsulates the entire study in a single file. Also, identifiable patient information is removed from the NRRD file. The file is thus anonymized. This is important when sending information over the Internet because we do not want identifiable patient information transmitted.
     
    Step 3: Upload the NRRD file to Embodi3D
     
    Now go to www.embodi3d.com, click on the democratiz3D navigation menu and select Launch App, as shown in Figure 7. Drag and drop your NRRD file where indicated. While NRRD file is uploading, fill in the "File Name" and "About This File" fields, as shown in Figure 8.
     

     
    Figure 7: Launching the democratiz3D application
     

     
    Figure 8: Uploading the NRRD file and entering basic information
    To complete basic information about your NRRD file. Do you want it to be private or do you want to share it with the community? Click on the Private File button if the former. If you are planning on sharing it, do you want it to be a free or a paid (licensed) file? Click the appropriate setting. Also select the License Type. If you are keeping the file private, these settings don't matter as the file will remain private. Make sure you accepted the Terms of Use, as shown in Figure 9.
     
     

    Figure 9: Basic information fields about your uploaded NRRD file
     
    Next, turn on democratiz3D Processing by selecting the slider under democratiz3D Processing. Make sure the operation CT NRRD to Bone STL is selected. Leave the default threshold of 150 in place. Choose an appropriate quality. Low quality produces small files quickly but the output resolution is low. Medium quality is good for most applications and produces a relatively good file that is not too large. High quality takes the longest to process and produces large output files. Bear in mind that if you upload a low quality NRRD file don't expect the high quality setting to produce a stellar bone model. Medium quality is good enough for most applications.
    If you wish, you have the option to specify whether you want your output file to be Private or Shared. If you're not sure, click Private. You can always change the visibility of the file later. If you're happy with your settings, click Save & Submit Files. This is shown in Figure 10.
     
     

    Figure 10: Entering the democratiz3D Processing parameters.
     
     
     
    Step 4: Review Your Completed Bone Model
    After about 10 to 20 minutes you should receive an email informing you that your file is ready for download. The actual processing time may vary depending on the size and complexity of the file and the load on the processing servers. Click on the link within the email. If you are already on the embodied site, you can access your file by going to your profile. Click your account in the upper right-hand corner and select Profile, as shown in Figure 11.
     
     

    Figure 11: Finding your profile.
     
    Your processed file will have the same name as the uploaded NRRD file, except it will end in "– processed". Renders of your new 3D model will be automatically generated within about 6 to 10 minutes. From your new model page you can click "Download this file" to download. If you wish to share your file with the community, you can toggle the privacy setting by clicking Privacy in the lower right-hand corner. You can edit your file or move it from one category to another under the File Actions button on the lower left. These are shown in Figure 12.
     
     

    Figure 12: Downloading, sharing, and editing your new 3D printable model.
     
    If you wish to sell your new file, you can change your selling settings under File Actions, Edit Details. Set the file type to be Paid, and specify a price. Please note that your file must be shared in order for other people to see it. This is shown in Figure 13. If you are going to sell your file, be sure you select General Paid File License from the License Type field, or specify your own customized license. For more information about selling files, click here.
     
     

    Figure 13: Making your new file available for sale on the Embodi3D marketplace.
     
     
    That's it! Now you can create your own 3D printable bone models in minutes for free and share or sell them with the click of a button.If you want to download the STL file created in this tutorial, you can download it here. Happy 3D printing!
     
  16. Like
    Dr. Mike reacted to mikefazz for a blog entry, Region Growing Image Segmentation   
    I wanted to take some time to look into a brief history of medical image segmentation before moving into what I consider the more modern method of segmentation.  (be warned video is rather long)
     
     
    First to be clear the goal of segmentation is to separate the bones or anatomy of interest from 3D scan data.  This is done most easily when there is a sharp contrast between the anatomy of interest and what surrounds it.  If you have a CT scan of an engine block this is pretty straight forward.  The density of metal to air is hard to beat, but for anatomy and especially MRI scans this is a whole other story.  Anatomical boundaries are often more of gradients than sharp edges.
     
    Over the years there have been many approaches to make the process of segmenting anatomy faster, easier, and less subjective then the dreaded 'manual segmentation'.  When I first started working with medical images back around 2003 the group I was at was trying an alternative to their previous method.  Their previous method involved using ImageJ to separate each bone of the foot by applying a threshold then going in and 'fixing' that by painting... They wanted to segment the bones of the foot and it would take like 10 hours of tedious labor... fortunately that was before my time.
    I was tasked with figuring out how to get 3DViewNix to work.  It was basically a research project that ran on linux (which I hadn't used before).  Its had a special algorithm called 'live-wire' which allowed clicking on a few points around the edge of the bone on each slice to get a closed contour that matched the bone edge then doing that for each scan slice for each bone.  This resulted in about 3 hours a foot of still rather mind numbing effort.
     

     
    After a while a radiologist with a PhD electrical engineering student let us know that there were much better ways.  His student had some software written in IDL that allowed using 'seeds' in each bone that would then grow out in 3D to the edges of the bones.  After some time to get setup we were able to segment a foot in less than an hour with a good portion of that being computer time.
     
    My background is as an ME so I don't pretend to fully understand the image processing algorithms but I have used them in various forms.  This year I got more familiar with 3DSlicer which I have found to be the best open source medical imaging program yet.  It is built off of VTK and ITK and has a very nice GUI making seeding far more convenient (other programs I've used didn't really allow zooming).  It took me a while to find something similar to what I had used before but eventually I found the extension 'FastGrowCut' gives very good results, enough to move away from the special software I had been using before that wasn't free.
     
    My basic explanation of 'FastGrowCut' and similar region growing algorithms is; you start with 'seeds' which are labeled voxels for the different anatomy of interest.  
       
    The algorithm then grows the seeds until it reaches the edge of the bone/anatomy or a different growing seed.  There is then a back and forth until it stabilizes on what the edge really is.  The result is a 'label' file which has all the voxels labeled as background or one of the entities of interest.  
     

     
    Once everything is segmented to the level that you like I prefer to do volumetric smoothing of each entity (bone) before creating the surface models.
     

     
    These algorithms are an active area of research typically in image processing groups within university electrical engineering departments.  The algorithms are not a silver bullet that works on all situations, there are a variety of other methods (some as extensions to 3DSlicer) for specific situations.  Thin features, long tubular features, noisy data (metal artifacts), low quality scans (scouts), will still take more time and effort to get good results.  No algorithm can take a low resolution, low quality scan and give you a nice model... garbage in = garbage out. 
     
    Now I have been surprised bemoaned to find thresholding used as a common segmentation technique, often as the main tool even in expensive commercial programs.  That style typically involves applying a threshold then going in and cleaning up the model until you get something close to what you want.  To me this seems rather antiquated but for quickly viewing data or creating a quick and rough model it really can't be beat... but for creating high quality models to be printed there are better ways.
  17. Like
    Dr. Mike got a reaction from lillux for a blog entry, Creating 3D Printable Medical Models and STL Files for Free: Online Services vs. Desktop Software - Slicer and Meshmixer   
    Note: This tutorial accompanies a workshop I presented at the 2016 Radiological Society of North America (RSNA) meeting. The workflow and techniques presented in this tutorial and the conference workshop are identical.
     

     
    In this tutorial we will be using two different ways to create a 3-D printable medical model of a head and neck which will be derived from a real contrast-enhanced CT scan. The model will show detailed anatomy of the bones, as well as the veins and arteries. We will independently create this model using two separate methods. First, we will automatically generate the model using the free online service embodi3D.com. Next, we will create the same file using free desktop software programs 3D Slicer and Meshmixer.
     
    If you haven't already, please download the associated file pack which contains the files you'll need to follow along with this tutorial. Following along with the actual files used here will make learning these techniques much easier. The file pack is free. You need to be logged into your embodi3D account to download, but registration is also free and only takes a minute. Also, you'll need an embodi3D.com account in order to use the online service. Registration is worth it, so if you haven't already go ahead and register now.
     
    >> DOWNLOAD THE FILE PACK NOW <<
     
    Online Service: embodi3D.com
     
     
    Step 1: Go to the embodi3D.com website and click on the democratiz3D menu item in the naw bar. Click on the "Launch democratizD" link, as shown in Figure 1.
     

    Figure 1: Opening the free online 3D model making service service democratiz3D.
     
    Step 2: Now you have to upload your imaging file. Drag and drop the file MANIX Angio CT.nrrd from the File Pack, as shown in Figure 2. This contains the CT scan of the head and neck in NRRD file format. If you are using a file other NRRD that provided by the file pack, please be aware the file must contain a CT scan (NOT MRI!) and the file must be in NRRD format. If you don't know how to create an NRRD file, here is a simple tutorial that explains how.
     

    Figure 2: Dragging and dropping the NRRD file to start uploading.
     
    Step 3: Type in basic information on the file being uploaded, including File name, file description, and whether you want to share the file or keep it private. Bear in mind that this information pertains to the uploaded file, not the file that will be generated by the service.

    Step 4: Type in basic parameters for file processing. Turn on the processing slider. Here you will enter in basic information about how you would like the file to be processed. Under Operation, select CT NRRD to Bone STL Detailed, as shown in Figure 3. This will convert a CT scan in NRRD format to a bone STL with high detail. You also have the option to create muscle and skin STL files. The standard operation, CT NRRD to Bone STL sacrifices some detail for a smoother output model. Leave the default threshold at 150.
     

    Figure 3: Selecting an operation for file conversion.
     
    Next, choose the quality of your output file. Low-quality files process quickly and are appropriate for structures with simple geometry. High quality files take longer to process and are appropriate for very complex geometry. The geometry of our model will be quite complex, so choose high quality. This may take a long time to process however, sometimes up to 40 minutes. If you don't wish to wait so long, you can choose medium quality, as shown in Figure 4, and have a pretty decent output file in about 12 minutes or so.
     
     

    Figure 4: Choosing a quality setting.
     
    Finally, specify whether you want your processed file to be shared with the community (encouraged) or private and accessible only to you. If you do decide to share you will need to fill out a few items, such as which CreativeCommons license to share under. If you're not sure, the defaults are appropriate for most people. If you do decide to share thanks very much! The 3D printing community thanks you!
     
    Click on the submit button and your file will be submitted for processing! Now all you have to do is wait. The service will do all the work for you!
     
    Step 5: Download your file. In 5 to 40 minutes you should receive an email indicating that your file is done and is ready for download. Follow the link in the email message or, if you are already on the embodi3D.com website, click on your profile to view your latest activity, including files belonging to you. Open the download page for your file and click on the "Download this file" button to download your newly created STL file!
     

    Figure 5: Downloading your newly completed STL file.
     
     
    Desktop software
    If you haven't already, download 3D Slicer and Meshmixer. Both of these programs are available on Macintosh and Windows platforms.
     
    Step 1: Create an STL file with 3D Slicer. Open 3D Slicer. Drag and drop the file MANIX Angio CT.nrrd from the file pack onto the 3D Slicer window. This should load the file into 3D Slicer, as shown in Figure 6. When Slicer asks you to confirm whether you want to add the file, click OK.
     

    Figure 6: Opening the NRRD file in 3D Slicer using drag-and-drop.
     
    Step 2: Convert the CT scan into an STL file. From within Slicer, open the Modules menu item and choose All Modules, Grayscale Model Maker, as shown in Figure 7.
     

    Figure 7: Opening the Grayscale Model Maker module.
     
    Next, enter the conversion parameters for Grayscale Model Maker in the parameters window on the left. Under Input Volume select MANIX Angio CT. Under Output Geometry choose "Create new model." Slicer will create a new model with the default name such as "Output Geometry. If you wish to rename this to something more descriptive, choose Rename current model under the same menu. For this tutorial I am calling the model "RSNA model."
     
    For Threshold, set the value to 150. Under Decimate, set the value to 0.75. Double check your settings to make sure everything is correct. When everything is filled in correctly click the Apply button, as shown in Figure 8. Slicer will process for about a minute.
     

    Figure 8: Filling in the Grayscale Model Maker parameters.
     
    Step 3: Save the new model to STL file format. Now it is time to create an STL file from our digital model. Click on the Save button on the upper left-hand corner of the Slicer window. The Save Scene pop-up window is now shown. Find the row that corresponds to the model name you have given the model. In my case it is called "RSNA model." Make sure that the checkbox next to this row is checked, and all other rows are unchecked. Next, under the File Format column make sure to specify STL. Finally, specify the directory that the new STL file is to be saved into. Double check everything. When you are ready, click Saved. This is all shown in Figure 9. Now that you've created an STL file, we need to postprocessing in Meshmixer.
     

    Figure 9: Saving your file to STL format.
     
    Step 4: Open Meshmixer, and drag-and-drop the newly created STL file onto the Meshmixer window to open it. Once the model opens, you will notice that there are many red dots scattered throughout the model. These represent errors in the mesh and need to be corrected, as shown in Figure 10.

    Figure 10: Errors in the mesh as shown in Meshmixer. Each red dot corresponds to an error.
     
    Step 5: Remove disconnected elements from the mesh. There are many disconnected elements in this model that we do not want in our final model. An example of unwanted mesh are the flat plates on either side of the head from the pillow that was used to secure the head during the CT scan. Let's get rid of this unwanted mesh.
     
    First use the select tool and place the cursor over the four head of the model and left click. The area under the cursor should turn orange, indicating that those polygons have been selected, as shown in Figure 11.
     

    Figure 11: Selecting a small zone on the forehead.
     
    Next, we are going to expand the selection to encompass all geometry that is attached to the area that we currently have selected. Go to the Modify menu item and select Expand to Connected. Alternatively, you can use the keyboard shortcut and select the E key. This operation is shown in Figure 12.
     

    Figure 12: Expanding the selection to all connected parts.
     
    You will notice that the right clavicle and right scapula have not been selected. This is because these parts are not directly connected to the rest of the skeleton, as shown in Figure 13. We wish to include these in our model, so using the select tool left click on each of these parts to highlight a small area. Then expand the selection to connected again by hitting the E key.
     

    Figure 13: The right clavicle and right scapula are not included in the selection because they are not connected to the rest of the skeleton. Individually select these parts and expand the selection again to include them.
     
    At this point you should have all the geometry we want included in the model selected in orange, as shown in Figure 14.
     

    Figure 14: All the desired geometry is selected in orange
     
    Next we are going to delete all the unwanted geometry that is currently unselected. To start this we will first invert the selection. Under the modify menu, select Invert. Alternatively, you can use the keyboard shortcut I, as shown in Figure 15.
     

    Figure 15: Inverting the selection.
     
    At this point only the undesired geometry should be highlighted in orange, as shown in Figure 16. This unwanted geometry cannot be deleted by going to the Edit menu and selecting Discard. Alternatively you can use the keyboard shortcut X.

    Figure 16: Only the unwanted geometry is highlighted in orange. This is ready to delete.
     
    Step 6: Correcting mesh errors using the Inspector tool. Meshmixer has a nice tool that will automatically fix many mesh errors. Click on the Analysis button and choose Inspector. Meshmixer will now identify all of the errors currently in the mesh. These are indicated by red, blue, and pink balls with lines pointing to the location of the error. As you can see from Figure 17, there are hundreds of errors still within our mesh. We can attempt to auto repair them by clicking on the Auto Repair All button. At the end of the operation most of the errors have been fixed, but if you remain. This can be seen in Figure 18.
     

    Figure 17: Errors in the mesh. Most of these can be corrected using the Inspector tool.
     

    Figure 18: Only a few errors remain after auto correction with the Inspector tool.
     
    Step 7: Correcting the remaining errors using the Remesh tool. Click on the select button to turn on the select tool. Expand the selection to connected parts by choosing Modify, Expand to Connected. The entire model should now be highlighted and origin color. Next under the edit menu choose Remesh, or use the R keyboard shortcut, as shown in Figure 19. This operation will take some time, six or eight minutes depending on the speed of your computer. What remesh does is it recalculates the surface topography of the model and replaces each of the surface triangles with new triangles that are more regular and uniform in appearance. Since our model has a considerable amount of surface area and polygons, the remesh operation takes some time. Remesh also has the ability to eliminate some geometric problems that can prevent all errors from being automatically fixed in Inspector.

    Figure 19: Using the Remesh tool.
     
    Step 8: Fixing the remaining errors using the Inspector tool. Once the remesh operation is completed we will go back and repeat Step 6 and run the Inspector tool again. Click on Analysis and choose Inspector. Inspector will highlight the errors. Currently there are only two, as shown in Figure 20. These two remaining errors can be easily auto repair using the Auto Repair All button. Go ahead and click on this.

    Figure 20: running the Inspector tool again.
     
    At this point the model is now completed and ready for 3D printing as shown in Figure 21. The mesh is error-free and ready to go! Congratulations!

    Figure 21: The final, error-free model ready for 3D printing.
    Conclusion
    Complex bone and vascular models, such as the head and neck model we created in this tutorial, can be created using either the free online service at embodi3D.com or using free desktop software. Each approach has its benefits. The online service is easier to use, faster, and produces high quality models with minimal user input. Additionally, multiple models can be processed simultaneously so it is possible to batch process multiple files at once. The desktop approach using 3D Slicer and Meshmixer requires more user input and thus more time, however the user has greater control over individual design decisions about the model. Both methods are viable for creating high quality 3D printable medical models.
     
    Thank you very much for reading this tutorial. Please share your medical 3D printing designs on the embodi3D.com website. Happy 3D printing!
  18. Like
    Dr. Mike got a reaction from ramon for a blog entry, How to Convert Multiple 3D Printable Bone Model STL Files from a CT Scan   
    Please note that any references to “Imag3D” in this tutorial has been replaced with “democratiz3D”
     
    In this tutorial you will learn how to create multiple 3D printable bone models simultaneously using the free online CT scan to bone STL converter, democratiz3D. We will use the free desktop program Slicer to convert our CT scan in DICOM format to NRRD format. We will also make a small section of the CT scan into its own NRRD file to create a second stand-alone model. The NRRD files will then be uploaded to the free democratiz3D online service to be converted into 3D printable STL models.
     
    If you haven't already, please see the tutorial A Ridiculously Easy Way to Convert CT Scans to 3D Printable Bone STL Models for Free in Minutes, which provides a good overview of the democratiz3D service.
     
    You should download the file pack that accompanies this tutorial. This contains an anonymized DICOM data set that will allow you to follow along with the tutorial.
     
    >>> DOWNLOAD THE TUTORIAL FILE PACK <<<
     
     
     
     
    Step 1: Register for an Embodi3D account

     
    If you haven't already done so, you'll need to register for an embodi3D account. Registration is free and only takes a minute. Once you are registered you'll receive a confirmatory email that verifies you are the owner of the registered email account. Click the link in the email to activate your account. The democratiz3D service will use this email account to send you notifications when your files are ready for download.
     
    Step 2: Create NRRD Files from DICOM with Slicer
     
    Open Slicer, which can be downloaded for free from www.slicer.org. Take the folder that contains your DICOM scan files and drag and drop it onto the slicer window, as shown in Figure 1. If you downloaded the tutorial file pack, a complete DICOM data set is included. Click OK when asked to load the study into the DICOM database. Click Copy when asked if you want to copy the images into the local database directory. Remember, this only works with CT scans. MRIs cannot be converted at this time.
     

    Figure 1: Dragging and dropping the DICOM folder onto the Slicer application. This will load the CT scan.
     
    A NRRD file that encompasses the entire scan can easily be created by clicking the save button at this point. Before we do that however, we are going to create a second NRRD file that only contains the lumbar spine, which will allow us to create a second 3D printable bone model of the lumbar spine. Open the CT scan by clicking on the Show DICOM Browser button, selecting the scan and series within the scan, and clicking the Load button. The CT scan will then load within the multipanel viewer.
     
    From the drop-down menu at the top left of the Slicer window, select All Modules and then Crop Volume, as shown in Figure 2. You will now want to create a Region Of Interest (ROI) to encompass the smaller volume we want to make. Turn on the ROI visibility button and then under the Input ROI drop-down menu, select "Create new AnnotationROI," As shown in Figure 3.
     

    Figure 2: Choosing the Crop Volume module
     

    Figure 3: Turn on ROI visibility and Create a new AnnotationROI under the Input ROI drop-down menu.
     
    A small cube will then be displayed in the blue volume window. This represents the sub volume that will be made. In its default position, the cube may not overlay the body, and may need to be dragged downward. Grab a control point on the cube and drag it downward (inferiorly) as shown in Figure 4.

    Figure 4: Grab the sub volume ROI and drag it downwards until it overlaps with the body.
     
    Next, use the control points on the volume box to position the volume box over the portion of the scan you wish to be included in the small 3D printable model, as shown in Figure 5.

    Figure 5: Adjusting the control points on the crop volume box.
     
    Once you have the box position where you want it, initiate the volume crop by clicking the Crop! button, as shown in Figure 6.

    Figure 6: The Crop! button
     
    You have now have two scan volumes that can be 3D printed. The first is the entire scan, and the second is the smaller sub volume that contains only the lumbar spine. We are now going to save those individual volumes as NRRD files. Click the Save button in the upper left-hand corner. In the Save Scene window, uncheck all items that do not have NRRD as the file format, as shown in Figure 7. Only NRRD file should be checked. Be sure to specify the directory that you want each file to be saved in.
     

    Figure 7: The Save Scene window
     
    Your NRRD files should now be saved in the directory you specified.
     
    Step 3: Upload your NRRD files and Convert to STL Files Using the Free democratiz3D Service
     
    Launch your web browser and go to www.embodi3d.com. If you haven't already register for a account. Registration is free and only takes a minute. Click on the democratiz3D navigation item and select Launch App, as shown in Figure 8.
     

    Figure 8: launching the democratiz3D application.
     
    Drag-and-drop both of your NRRD files onto the upload panel. Fill in the required fields, including a title, short description, privacy setting (private versus shared), and license type. You must agree to the terms of use. Please note that even though license type is a required field, it only matters if the file is shared. If you keep the file private and thus not available to other members on the site, they will not see it nor be able to download it.
     
    Be sure to turn on the democratiz3D Processing slider! If you don't turn this on your file will not be processed but will just be saved in your account on the website. It should be green when turned on. Once you turn on democratiz3D Processing, you'll be presented with some basic processing options, as shown in Figure 9. Leave the default operation as "CT NRRD to Bone STL," which is the operation that creates a basic bone model from a CT scan in NRRD format. Threshold is the Hounsfield attenuation to use for selecting the bones. The default value of 150 is good for most applications, but if you have a specialized model you wish to create, you can adjust this value. Quality denotes the number of polygons in your output file. High-quality may take longer to process and produce larger files. These are more appropriate for very large or detailed structures, such as an entire spinal column. Low quality is best for small structures that are geometrically simple, such as a patella. Medium quality is balanced, and is appropriate for most circumstances.
     

    Figure 9: The democratiz3D File Processing Parameters.
     
    Once you are satisfied with your processing parameters, click submit. Both of your nrrd files will be processed in two separate bone STL files, as shown in Figure 10. The process takes 10 to 20 minutes and you will receive an email notifying you that your files are ready. Please note, the stl processing will finish first followed by the images. Click on the thumbnails for each model to access the file for download or click the title.
     

    Figure 10:  Two files have been processed simultaneously and are ready for download
     
    Step 4: CT scan conversion is complete your STL bone model files are ready for 3D Printing
    That's it! Both of your bone models are ready for 3D printing. I hope you enjoyed this tutorial. Please use the democratiz3D service and  SHARE the files you create with the community by changing their status from private or shared. Thank you very much and happy 3D printing!
  19. Like
    Dr. Mike reacted to valchanov for a blog entry, Atlas and Axis, 3D PDF   
    Hello
    My recent anatomy projects forced me to start importing my 3d models into 3d pdf documents. So I'll share with you some of my findings.
    The positive things about 3d pdf's are:
    1. You can import a big sized 3d model and compress it into a small 3d pdf. 40 Mb stl model is converted into 750 Kb pdf.
    2. You can run the 3d pdf on every computer with the recent versions of Adobe Acrobat Reader. Which means literally EVERY computer.
    3. You can rotate, pan, zoom in and zoom out 3d models in the 3d pdf. You can add some simple animations like spinning, sequence animations and explosion of multi component models.
    4. You can add colors to the models and to create a 3d scene.
    5. You can upload it on a website and it can be viewed in the browser (if Adobe Acrobat Reader is installed).
    The negative things are:
    1. Adobe Reader is a buggy 3d viewer. If you import a big model (bigger than 50 Mb) and your computer is business class (core I3 or I5, 4 Gb ram, integrated video card), you'll experience some nasty lag and the animation will look terrible. On the same computer regular 3d viewer will do the trick much better.
    2. You can experience some difficulties with multi component models. During the rotation, some of the components will disappear, others will change their color. Also the model navigation toolbar is somewhat hard to control.
    3. The transparent and wireframe polygon are not as good as in the regular 3d viewers.
    The conclusion:
    If you want to demonstrate your models to a large audience, to sent it via email and to observe them on every computer, 3d pdf is your format. For a presentation it's better to use a regular 3d viewer, even the portable ones will do the trick. But if the performance is not the goal, 3d pdf's  are a good alternative.
    Here is a model of atlas and axis as 3d pfg: https://www.dropbox.com/s/2gm7occq5ur50um/vertebra.pdf?dl=0
    Best regards,
    Peter
     

  20. Like
    Dr. Mike got a reaction from tsehrhardt for a blog entry, A Ridiculously Easy Way to Convert CT Scans to 3D Printable Bone STL Models for Free in Minutes   
    Please note the democratiz3D service was previously named "Imag3D"
    In this tutorial you will learn how to quickly and easily make 3D printable bone models from medical CT scans using the free online service democratiz3D®. The method described here requires no prior knowledge of medical imaging or 3D printing software. Creation of your first model can be completed in as little as 10 minutes.
     
    You can download the files used in this tutorial by clicking on this link. You must have a free Embodi3D member account to do so. If you don't have an account, registration is free and takes a minute. It is worth the time to register so you can follow along with the tutorial and use the democratiz3D service.
     
    >> DOWNLOAD TUTORIAL FILES AND FOLLOW ALONG <<
    Both video and written tutorials are included in this page.
     
     
     
     
     
    Before we start you'll need to have a copy of a CT scan. If you are interested in 3D printing your own CT scan, you can go to the radiology department of the hospital or clinic that did the scan and ask for the scan to be put on a CD or DVD for you. Figures 1 and 2 show the radiology department at my hospital, called Image Management, and the CDs that they give out. Most radiology departments will have you sign a written release and give you a CD or DVD for free or with a small processing fee. If you are a doctor or other healthcare provider and want to 3D print a model for a patient, the radiology department can also help you. There are multiple online repositories of anonymized CT scans for research that are also available.
     
     

    Figure 1: The radiology department window at my hospital.
     

     
     
    Figure 2: An example of what a DVD containing a CT scan looks like. This looks like a standard CD or DVD.
     
     
     
    Step 1: Register for an Embodi3D account
     
    If you haven't already done so, you'll need to register for an embodi3d account. Registration is free and only takes a minute. Once you are registered you'll receive a confirmatory email that verifies you are the owner of the registered email account. Click the link in the email to activate your account. The democratiz3D service will use this email account to send you notifications when your files are ready for download.
     
    Step 2: Create an NRRD file with Slicer
    If you haven't already done so, go to slicer.org and download Slicer for your operating system. Slicer is a free software program for medical imaging research. It also has the ability to save medical imaging scans in a variety of formats, which is what we will use it for in this tutorial.
    Next, launch Slicer. Insert your CD or DVD containing the CT scan into your computer and open the CD with File Explorer or equivalent file browsing application for your operating system. You should find a folder that contains numerous DICOM files in it, as shown in Figure 3. Drag-and-drop the entire DICOM folder onto the Slicer welcome page, as shown in Figure 4. Click OK when asked to load the study into the DICOM database. Click Copy when asked if you want to copy the images into the local database directory.
     
     

    Figure 3: A typical DICOM data set contains numerous individual DICOM files.
     
     

    Figure 4: Dragging and dropping the DICOM folder onto the Slicer application. This will load the CT scan.
     
    Once Slicer has finished loading the study, click the save icon in the upper left-hand corner as shown in Figure 5. One of the files in the list will be of type NRRD. make sure that this file is checked and all other files are unchecked. click on the directory button for the NRRD file and select an appropriate directory to save the file. then click Save, as shown in Figure 6.
     
     

    Figure 5: The Save button
     

     
    Figure 6: The Save File box
     
    The NRRD file is much better for uploading then DICOM. Instead of having multiple files in a DICOM data set, the NRRD file encapsulates the entire study in a single file. Also, identifiable patient information is removed from the NRRD file. The file is thus anonymized. This is important when sending information over the Internet because we do not want identifiable patient information transmitted.
     
    Step 3: Upload the NRRD file to Embodi3D
     
    Now go to www.embodi3d.com, click on the democratiz3D navigation menu and select Launch App, as shown in Figure 7. Drag and drop your NRRD file where indicated. While NRRD file is uploading, fill in the "File Name" and "About This File" fields, as shown in Figure 8.
     

     
    Figure 7: Launching the democratiz3D application
     

     
    Figure 8: Uploading the NRRD file and entering basic information
    To complete basic information about your NRRD file. Do you want it to be private or do you want to share it with the community? Click on the Private File button if the former. If you are planning on sharing it, do you want it to be a free or a paid (licensed) file? Click the appropriate setting. Also select the License Type. If you are keeping the file private, these settings don't matter as the file will remain private. Make sure you accepted the Terms of Use, as shown in Figure 9.
     
     

    Figure 9: Basic information fields about your uploaded NRRD file
     
    Next, turn on democratiz3D Processing by selecting the slider under democratiz3D Processing. Make sure the operation CT NRRD to Bone STL is selected. Leave the default threshold of 150 in place. Choose an appropriate quality. Low quality produces small files quickly but the output resolution is low. Medium quality is good for most applications and produces a relatively good file that is not too large. High quality takes the longest to process and produces large output files. Bear in mind that if you upload a low quality NRRD file don't expect the high quality setting to produce a stellar bone model. Medium quality is good enough for most applications.
    If you wish, you have the option to specify whether you want your output file to be Private or Shared. If you're not sure, click Private. You can always change the visibility of the file later. If you're happy with your settings, click Save & Submit Files. This is shown in Figure 10.
     
     

    Figure 10: Entering the democratiz3D Processing parameters.
     
     
     
    Step 4: Review Your Completed Bone Model
    After about 10 to 20 minutes you should receive an email informing you that your file is ready for download. The actual processing time may vary depending on the size and complexity of the file and the load on the processing servers. Click on the link within the email. If you are already on the embodied site, you can access your file by going to your profile. Click your account in the upper right-hand corner and select Profile, as shown in Figure 11.
     
     

    Figure 11: Finding your profile.
     
    Your processed file will have the same name as the uploaded NRRD file, except it will end in "– processed". Renders of your new 3D model will be automatically generated within about 6 to 10 minutes. From your new model page you can click "Download this file" to download. If you wish to share your file with the community, you can toggle the privacy setting by clicking Privacy in the lower right-hand corner. You can edit your file or move it from one category to another under the File Actions button on the lower left. These are shown in Figure 12.
     
     

    Figure 12: Downloading, sharing, and editing your new 3D printable model.
     
    If you wish to sell your new file, you can change your selling settings under File Actions, Edit Details. Set the file type to be Paid, and specify a price. Please note that your file must be shared in order for other people to see it. This is shown in Figure 13. If you are going to sell your file, be sure you select General Paid File License from the License Type field, or specify your own customized license. For more information about selling files, click here.
     
     

    Figure 13: Making your new file available for sale on the Embodi3D marketplace.
     
     
    That's it! Now you can create your own 3D printable bone models in minutes for free and share or sell them with the click of a button.If you want to download the STL file created in this tutorial, you can download it here. Happy 3D printing!
     
  21. Like
    Dr. Mike got a reaction from SJSato for a blog entry, Formlabs Form 2 3D Printer Review: A Great Buy for Medical 3D Printing   
    Hello Dr. Mike here and welcome to my review of the Form 2 3D printer by Formlabs. The Form 2 is Formlabs newest desktop stereolithography printer. It is a great asset for medical 3D printing with many user friendly features and an acceptable price.
     
    My full review is included here in both video and text. You can download the splenic artery aneurysm file shown in the video. The Form 2 printer is available to purchase. The previous generation Form 1+ can be purchased on Amazon. However, the Form 2 represents a better value.
     
    Stereolithography is a 3D printing method where a laser hardens liquid resin in a vat one layer at a time. This is different from fused deposition modeling (FDM) where plastic filament is heated and extruded through a nozzle to make the 3-D print. Stereolithography is capable of producing highly detailed 3-D prints with a layer thickness of 25 µm. This is four times finer than the 100 µm layer thickness for the latest MakerBot Replicator.
     
     
    Form 2 Unboxing and Set Up
    My Form 2 arrived in a series of boxes at my front door. I do a lot of 3-D printing so I ordered extra bill platforms and resin tanks. Resin cartridges came in their own separate box. As you can see I also ordered extra resin cartridges.
     
    The Form 2 printer came in a large box that contained a quick start guide, another resin tank, build platform, and accessories. The printer itself was well secured in the box and had convenient pullout handles. Once the printer was in its final location next to my old form 1+ printers I had to remove the extensive tape used to secure the printer during shipping. A thin plastic protective film is present over the touchscreen. I tend to get my printers dirty so I left this in place.
     
    Next I plugged in the printer, and it immediately started to initialize. The printer immediately gave me a warning that it was not level. I had the printer set up on the same table that my older Form 1+ printers were on but they do not have a leveling sensor, and apparently I have been printing with them leveled all this time.
     
    Fortunately leveling the Form 2 printer is very easy. It has screw type legs that can be raised or lowered, much the same way that restaurant tables can be adjusted. A simple disc like leveling tool comes with the printer and can be used to adjust the legs easily. Adjust the legs until the leveling circle is within the bull's-eye shown on the main screen. This is a pretty cool feature. The printer is now ready to print.
     
    You can connect to the printer over a USB cable, but I prefer Wi-Fi as my main computer is in a different room than the printer. To do this turn on Wi-Fi settings and select your network. The older Form 1+ printer resin came in bottles that you had to pour into the resin tank. The Form 2 printer comes with a printer cartridge that slides into the back of the printer. When you're resin tank is low the printer automatically fills the tank from the cartridge. This is quite handy especially with larger prints that may require the tank to otherwise be refilled in the middle of a print.
     
    A new resin tank fits easily into the printer and snaps in place. Resin tanks are considered to be consumables and are thrown out after about 2 L of printing when the floor of the tank becomes foggy and starts to inhibit the laser. Each resin tank comes with a wiper arm which snaps into place. This wiper arm is a new feature for the form to and can prevent cured resin from sticking to the bottom of the tank, a situation that in older printers could cause total print failure. With the new wiper arm this situation is much less likely to happen.
    The new build platform slides and easily.
     
    Inserting a resin cartridges a snap. There's a cap on the top of the resin cartridge that should be opened to allow resin to drain into the printer. At this point the printer should be ready to print. You can see that the display shows that a resin tank and cartridge have been inserted. Also the display indicates the internal temperature. During printing a heater will warm the internal temperature to the appropriate level to achieve best results.
     
    This is the result of my first print, which is a hollow vascular model. This is my second print which is a section of lumbar spine printed in clear resin.
     
    This is the new removal tool, which is used to remove the three printed model from the build platform. Form labs has recently released firmware update which makes removal of the parts much easier. The removal tool can slip under the edges and with gentle twisting will separate from the bill platform. This is a significant improvement over the older support structure. It is also an example of how form labs continues to improve its products even after sale through the use of software upgrades.
     
    Once removed from the bill platform the support structures need to be removed. This can be done either before or after cleaning the part in an alcohol bath. The model will be covered in sticky resin so you need to wear disposable gloves and be able to clean the parts with alcohol, which requires decent ventilation. Using the flush cutters that come with the kit the base can be cut and the support structures can be gently worked off the model.
     
    Here's an example of a splenic artery aneurysm model that I printed and clear. You can see that the quality of the print is excellent. If you would like to 3-D print this model yourself I have made it free for download at the link in the description below. It is available in both STL and Form labs Preform software format. This is an example of some of the parts that are produced with the Form 2 printer. As you can see they are a very high quality.
     
    Purchase and material options, and other features
    The Form 2 comes with many upgrades and improvements over its predecessor, the Form 1+. This includes:
    Larger build volume, 14.5 x 14.5 x 17.5 cm Heated tank slide peeled resin wiper dust protection automated resin system wireless connectivity
    The cost of the Form 2 printer is $3499, which includes the printer, resin tank, build platform, finishing kit, and one liter of resin of your choice. The printer comes with a one-year warranty.
     

    Standard resins are available in black, gray, white, and clear. Functional resins include flexible, castable, and tough. A biocompatible resin is available for dental purposes.
     
    Form 2 For Medical 3D Printing Review Conclusion
    The Form 2 is an outstanding desktop stereolithography 3-D printer for the price. It produces very high quality parts. It is expensive for a consumer grade desktop printer but is significantly cheaper than other printers used for medical purposes. The free Preform software makes setting up a print easy. Cons of the printer are it is messy, requiring gloves and isopropyl alcohol to clean the sticky resin from the parts. This can be a problem in a poorly ventilated office environment. Also the build volume, while larger than its predecessor, is still smaller than many FDM printers.
    Overall the form two is an outstanding value and I recommend it highly particularly for medical 3-D printing. Thank you very much for watching if you like this video subscribe below and happy 3-D printing.
  22. Like
    Dr. Mike got a reaction from SJSato for a blog entry, 3D Printing a Spine Model to Help a Fellow Doctor with Low Back Pain   
    I was recently contacted by another doctor who asked if I could help him to create a 3D printed replicate of his spine to visualize pinched nerves in his low back and aid with planning a future back surgery. In order to work this doctor has to stand for long hours while performing surgical procedures. Excruciating low back pain had limited his ability to stand to only 30 minutes. As you can imagine, this means he couldn't work. Things only got worse after he had low back surgery.
     
    A CT scan of his lumbar spine (the low back portion of the spine) was performed. It showed that his fifth lumbar vertebra was partially sacralized. This means it looked more like a sacral vertebra than a lumbar vertebra. Was this causing his problem? On the image slices of the CT scan it was difficult to tell.
     
    How the Spine is Organized
    First, a word about the different vertebrae (bones) in the spine. There are four main sections of spinal bones. The seven cervical vertebrae are in the neck and support the head. They are generally small but flexible, and allow rotation of the head. The 12 thoracic vertebrae are in the chest. Their most distinctive characteristic is they all have associated ribs, which make up the rib cage. The five lumbar vertebrae are in the low back. These are large and strong, and designed for supporting lots of weight. They do not have associated ribs. The five sacral vertebrae are in the pelvis. In adults, they are fused together and effectively form a single bone, the sacrum. The coccyx, or tailbone, which is a tiny bone at the bottom end of the vertebral column, can be considered a fifth spinal section. This is the bone that is often injured when you fallen your behind. Figure 1 shows the different sections of the vertebral column.
     

    Figure 1. Sections of the vertebral column. Source:aimisspine.com
     
    Although the bones of the individual sections of the spine usually have their own unique features, it is not uncommon for vertebrae in one section to have features typically associated with an adjacent section. This is particularly true of the vertebrae that are immediately adjacent to a neighboring section. These hybrids are a mix between both sections, are called transitional vertebrae. Do you recall that only thoracic vertebrae have associated ribs? Occasionally the highest lumbar vertebra, L1, will have tiny ribs attached to it. This is a normal variant and is usually harmless. Radiologists who are interpreting medical scans need to be careful to not confuse an L1 vertebra which may have tiny ribs for the adjacent T12 vertebra which normally has ribs. Similarly, the lowest lumbar vertebra, L5, which is normally unfused, can exhibit fusion. As you recall, fusion is a characteristic of sacral vertebrae.
     
    A Congenital Spine Abnormality
    This was the situation with our physician. His lowest lumbar vertebra, L5, has partially fused with S1, the highest sacral vertebra. This condition is congenital. He has had it all his life. The fusion can have the side effect of creating a very narrow bony canal through which the L5 nerve roots can exit the spine. Normally, these nerve roots would have much more space as a large gap would exist between the normally unfused L5 and S1 vertebrae. Was this the problem? The CT scan showed the sacralization of L5, but it was difficult to get a sense for how tight the holes through which the nerves exit, the neural foramina, were. See Figures 2 and 3.
     

     
    Figure 2: Coronal CT image through the L5 and S1 vertebral bodies. Is this the cause of the problem? It is very difficult to get an intuitive sense of what is going on with these flat image slices.
     

     
    Figure 3: Image from Figure 2 with the neural foramina marked.
     
    Seeking help through Embodi3D
    The doctor contacted me through the Embodi3D website and asked if I could create a 3D model design and 3D print of his lumbar spine to help him and his team of spinal specialists understand his unique anatomy better. Of course, I was happy to help. The CT scan was of high quality and allowed me to extract the bones and metallic spinal fusion implants with little trouble. The individual nerves, however, were very difficult to see even on a high quality CT scan. I had to manually segment them one image at a time, which was a very tedious and time-consuming process. After fusing everything together, I had a very good digital model of the lumbar spine. I created some photorealistic 3D renders to illustrate the key findings.
     
    Figures 4 and 5 show the very tight L5-S1 bony neural foramina. The inter-vertebral disc sits within the gap between the two vertebral bodies, and you can see how a lateral bulge from this disc would significantly pinch these exiting nerve roots.
     

     
    Figure 4: Right L5 nerve root (yellow) exiting the tight neural foramen caused by the fused L5 and S1 lateral processes.
     

     
    Figure 5: Left L5 nerve root (yellow) exiting the tight neural foramen caused by the fused L5 and S1 lateral processes.
     
    Additionally, I showed that a bone screw that had been placed during the last surgery had partially exited the L4 vertebral body and was in very close proximity, and probably touching, the adjacent nerve root. Ouch! This can be seen in Figure 6. This may explain why the pain seem to get worse after the last surgery.
     

     
    Figure 6: Transpedicular orthopedic screw which has partially exited the L4 vertebral body and is in very close proximity or in contact with the right L3 nerve root.
     
    The Final 3D Printed Spine Model
    The doctor wanted his spine 3D printed in transparent material, so I used a stereolithographic printer with transparent resin. I printed the spine in two separate parts that could be separated and fit together. When separated, the nerves exiting through the neural foramina can be inspected from inside the spinal canal, which gives an added degree of understanding.
     
    Final pictures of the transparent 3D printed model are shown below.
     
     

     

     
     

     
     

     
     

     
     
     
    I just recently shipped the model to this doctor and don't yet know how his back problems will be resolved. With this 3D printed model in hand however, he will be able to have much more meaningful discussions with his spinal surgeons about the best way to definitively fix his low back problems. I hope that the 3D printed spine model will literally help to get this good doctor back on his feet again.
  23. Like
    Dr. Mike got a reaction from balaji for a blog entry, 3D Printing a Spine Model to Help a Fellow Doctor with Low Back Pain   
    I was recently contacted by another doctor who asked if I could help him to create a 3D printed replicate of his spine to visualize pinched nerves in his low back and aid with planning a future back surgery. In order to work this doctor has to stand for long hours while performing surgical procedures. Excruciating low back pain had limited his ability to stand to only 30 minutes. As you can imagine, this means he couldn't work. Things only got worse after he had low back surgery.
     
    A CT scan of his lumbar spine (the low back portion of the spine) was performed. It showed that his fifth lumbar vertebra was partially sacralized. This means it looked more like a sacral vertebra than a lumbar vertebra. Was this causing his problem? On the image slices of the CT scan it was difficult to tell.
     
    How the Spine is Organized
    First, a word about the different vertebrae (bones) in the spine. There are four main sections of spinal bones. The seven cervical vertebrae are in the neck and support the head. They are generally small but flexible, and allow rotation of the head. The 12 thoracic vertebrae are in the chest. Their most distinctive characteristic is they all have associated ribs, which make up the rib cage. The five lumbar vertebrae are in the low back. These are large and strong, and designed for supporting lots of weight. They do not have associated ribs. The five sacral vertebrae are in the pelvis. In adults, they are fused together and effectively form a single bone, the sacrum. The coccyx, or tailbone, which is a tiny bone at the bottom end of the vertebral column, can be considered a fifth spinal section. This is the bone that is often injured when you fallen your behind. Figure 1 shows the different sections of the vertebral column.
     

    Figure 1. Sections of the vertebral column. Source:aimisspine.com
     
    Although the bones of the individual sections of the spine usually have their own unique features, it is not uncommon for vertebrae in one section to have features typically associated with an adjacent section. This is particularly true of the vertebrae that are immediately adjacent to a neighboring section. These hybrids are a mix between both sections, are called transitional vertebrae. Do you recall that only thoracic vertebrae have associated ribs? Occasionally the highest lumbar vertebra, L1, will have tiny ribs attached to it. This is a normal variant and is usually harmless. Radiologists who are interpreting medical scans need to be careful to not confuse an L1 vertebra which may have tiny ribs for the adjacent T12 vertebra which normally has ribs. Similarly, the lowest lumbar vertebra, L5, which is normally unfused, can exhibit fusion. As you recall, fusion is a characteristic of sacral vertebrae.
     
    A Congenital Spine Abnormality
    This was the situation with our physician. His lowest lumbar vertebra, L5, has partially fused with S1, the highest sacral vertebra. This condition is congenital. He has had it all his life. The fusion can have the side effect of creating a very narrow bony canal through which the L5 nerve roots can exit the spine. Normally, these nerve roots would have much more space as a large gap would exist between the normally unfused L5 and S1 vertebrae. Was this the problem? The CT scan showed the sacralization of L5, but it was difficult to get a sense for how tight the holes through which the nerves exit, the neural foramina, were. See Figures 2 and 3.
     

     
    Figure 2: Coronal CT image through the L5 and S1 vertebral bodies. Is this the cause of the problem? It is very difficult to get an intuitive sense of what is going on with these flat image slices.
     

     
    Figure 3: Image from Figure 2 with the neural foramina marked.
     
    Seeking help through Embodi3D
    The doctor contacted me through the Embodi3D website and asked if I could create a 3D model design and 3D print of his lumbar spine to help him and his team of spinal specialists understand his unique anatomy better. Of course, I was happy to help. The CT scan was of high quality and allowed me to extract the bones and metallic spinal fusion implants with little trouble. The individual nerves, however, were very difficult to see even on a high quality CT scan. I had to manually segment them one image at a time, which was a very tedious and time-consuming process. After fusing everything together, I had a very good digital model of the lumbar spine. I created some photorealistic 3D renders to illustrate the key findings.
     
    Figures 4 and 5 show the very tight L5-S1 bony neural foramina. The inter-vertebral disc sits within the gap between the two vertebral bodies, and you can see how a lateral bulge from this disc would significantly pinch these exiting nerve roots.
     

     
    Figure 4: Right L5 nerve root (yellow) exiting the tight neural foramen caused by the fused L5 and S1 lateral processes.
     

     
    Figure 5: Left L5 nerve root (yellow) exiting the tight neural foramen caused by the fused L5 and S1 lateral processes.
     
    Additionally, I showed that a bone screw that had been placed during the last surgery had partially exited the L4 vertebral body and was in very close proximity, and probably touching, the adjacent nerve root. Ouch! This can be seen in Figure 6. This may explain why the pain seem to get worse after the last surgery.
     

     
    Figure 6: Transpedicular orthopedic screw which has partially exited the L4 vertebral body and is in very close proximity or in contact with the right L3 nerve root.
     
    The Final 3D Printed Spine Model
    The doctor wanted his spine 3D printed in transparent material, so I used a stereolithographic printer with transparent resin. I printed the spine in two separate parts that could be separated and fit together. When separated, the nerves exiting through the neural foramina can be inspected from inside the spinal canal, which gives an added degree of understanding.
     
    Final pictures of the transparent 3D printed model are shown below.
     
     

     

     
     

     
     

     
     

     
     
     
    I just recently shipped the model to this doctor and don't yet know how his back problems will be resolved. With this 3D printed model in hand however, he will be able to have much more meaningful discussions with his spinal surgeons about the best way to definitively fix his low back problems. I hope that the 3D printed spine model will literally help to get this good doctor back on his feet again.
  24. Like
    Dr. Mike got a reaction from MrSchaeffer for a blog entry, 3D Printing a Spine Model to Help a Fellow Doctor with Low Back Pain   
    I was recently contacted by another doctor who asked if I could help him to create a 3D printed replicate of his spine to visualize pinched nerves in his low back and aid with planning a future back surgery. In order to work this doctor has to stand for long hours while performing surgical procedures. Excruciating low back pain had limited his ability to stand to only 30 minutes. As you can imagine, this means he couldn't work. Things only got worse after he had low back surgery.
     
    A CT scan of his lumbar spine (the low back portion of the spine) was performed. It showed that his fifth lumbar vertebra was partially sacralized. This means it looked more like a sacral vertebra than a lumbar vertebra. Was this causing his problem? On the image slices of the CT scan it was difficult to tell.
     
    How the Spine is Organized
    First, a word about the different vertebrae (bones) in the spine. There are four main sections of spinal bones. The seven cervical vertebrae are in the neck and support the head. They are generally small but flexible, and allow rotation of the head. The 12 thoracic vertebrae are in the chest. Their most distinctive characteristic is they all have associated ribs, which make up the rib cage. The five lumbar vertebrae are in the low back. These are large and strong, and designed for supporting lots of weight. They do not have associated ribs. The five sacral vertebrae are in the pelvis. In adults, they are fused together and effectively form a single bone, the sacrum. The coccyx, or tailbone, which is a tiny bone at the bottom end of the vertebral column, can be considered a fifth spinal section. This is the bone that is often injured when you fallen your behind. Figure 1 shows the different sections of the vertebral column.
     

    Figure 1. Sections of the vertebral column. Source:aimisspine.com
     
    Although the bones of the individual sections of the spine usually have their own unique features, it is not uncommon for vertebrae in one section to have features typically associated with an adjacent section. This is particularly true of the vertebrae that are immediately adjacent to a neighboring section. These hybrids are a mix between both sections, are called transitional vertebrae. Do you recall that only thoracic vertebrae have associated ribs? Occasionally the highest lumbar vertebra, L1, will have tiny ribs attached to it. This is a normal variant and is usually harmless. Radiologists who are interpreting medical scans need to be careful to not confuse an L1 vertebra which may have tiny ribs for the adjacent T12 vertebra which normally has ribs. Similarly, the lowest lumbar vertebra, L5, which is normally unfused, can exhibit fusion. As you recall, fusion is a characteristic of sacral vertebrae.
     
    A Congenital Spine Abnormality
    This was the situation with our physician. His lowest lumbar vertebra, L5, has partially fused with S1, the highest sacral vertebra. This condition is congenital. He has had it all his life. The fusion can have the side effect of creating a very narrow bony canal through which the L5 nerve roots can exit the spine. Normally, these nerve roots would have much more space as a large gap would exist between the normally unfused L5 and S1 vertebrae. Was this the problem? The CT scan showed the sacralization of L5, but it was difficult to get a sense for how tight the holes through which the nerves exit, the neural foramina, were. See Figures 2 and 3.
     

     
    Figure 2: Coronal CT image through the L5 and S1 vertebral bodies. Is this the cause of the problem? It is very difficult to get an intuitive sense of what is going on with these flat image slices.
     

     
    Figure 3: Image from Figure 2 with the neural foramina marked.
     
    Seeking help through Embodi3D
    The doctor contacted me through the Embodi3D website and asked if I could create a 3D model design and 3D print of his lumbar spine to help him and his team of spinal specialists understand his unique anatomy better. Of course, I was happy to help. The CT scan was of high quality and allowed me to extract the bones and metallic spinal fusion implants with little trouble. The individual nerves, however, were very difficult to see even on a high quality CT scan. I had to manually segment them one image at a time, which was a very tedious and time-consuming process. After fusing everything together, I had a very good digital model of the lumbar spine. I created some photorealistic 3D renders to illustrate the key findings.
     
    Figures 4 and 5 show the very tight L5-S1 bony neural foramina. The inter-vertebral disc sits within the gap between the two vertebral bodies, and you can see how a lateral bulge from this disc would significantly pinch these exiting nerve roots.
     

     
    Figure 4: Right L5 nerve root (yellow) exiting the tight neural foramen caused by the fused L5 and S1 lateral processes.
     

     
    Figure 5: Left L5 nerve root (yellow) exiting the tight neural foramen caused by the fused L5 and S1 lateral processes.
     
    Additionally, I showed that a bone screw that had been placed during the last surgery had partially exited the L4 vertebral body and was in very close proximity, and probably touching, the adjacent nerve root. Ouch! This can be seen in Figure 6. This may explain why the pain seem to get worse after the last surgery.
     

     
    Figure 6: Transpedicular orthopedic screw which has partially exited the L4 vertebral body and is in very close proximity or in contact with the right L3 nerve root.
     
    The Final 3D Printed Spine Model
    The doctor wanted his spine 3D printed in transparent material, so I used a stereolithographic printer with transparent resin. I printed the spine in two separate parts that could be separated and fit together. When separated, the nerves exiting through the neural foramina can be inspected from inside the spinal canal, which gives an added degree of understanding.
     
    Final pictures of the transparent 3D printed model are shown below.
     
     

     

     
     

     
     

     
     

     
     
     
    I just recently shipped the model to this doctor and don't yet know how his back problems will be resolved. With this 3D printed model in hand however, he will be able to have much more meaningful discussions with his spinal surgeons about the best way to definitively fix his low back problems. I hope that the 3D printed spine model will literally help to get this good doctor back on his feet again.
  25. Like
    Dr. Mike got a reaction from lillux for a blog entry, 3D Printing a Spine Model to Help a Fellow Doctor with Low Back Pain   
    I was recently contacted by another doctor who asked if I could help him to create a 3D printed replicate of his spine to visualize pinched nerves in his low back and aid with planning a future back surgery. In order to work this doctor has to stand for long hours while performing surgical procedures. Excruciating low back pain had limited his ability to stand to only 30 minutes. As you can imagine, this means he couldn't work. Things only got worse after he had low back surgery.
     
    A CT scan of his lumbar spine (the low back portion of the spine) was performed. It showed that his fifth lumbar vertebra was partially sacralized. This means it looked more like a sacral vertebra than a lumbar vertebra. Was this causing his problem? On the image slices of the CT scan it was difficult to tell.
     
    How the Spine is Organized
    First, a word about the different vertebrae (bones) in the spine. There are four main sections of spinal bones. The seven cervical vertebrae are in the neck and support the head. They are generally small but flexible, and allow rotation of the head. The 12 thoracic vertebrae are in the chest. Their most distinctive characteristic is they all have associated ribs, which make up the rib cage. The five lumbar vertebrae are in the low back. These are large and strong, and designed for supporting lots of weight. They do not have associated ribs. The five sacral vertebrae are in the pelvis. In adults, they are fused together and effectively form a single bone, the sacrum. The coccyx, or tailbone, which is a tiny bone at the bottom end of the vertebral column, can be considered a fifth spinal section. This is the bone that is often injured when you fallen your behind. Figure 1 shows the different sections of the vertebral column.
     

    Figure 1. Sections of the vertebral column. Source:aimisspine.com
     
    Although the bones of the individual sections of the spine usually have their own unique features, it is not uncommon for vertebrae in one section to have features typically associated with an adjacent section. This is particularly true of the vertebrae that are immediately adjacent to a neighboring section. These hybrids are a mix between both sections, are called transitional vertebrae. Do you recall that only thoracic vertebrae have associated ribs? Occasionally the highest lumbar vertebra, L1, will have tiny ribs attached to it. This is a normal variant and is usually harmless. Radiologists who are interpreting medical scans need to be careful to not confuse an L1 vertebra which may have tiny ribs for the adjacent T12 vertebra which normally has ribs. Similarly, the lowest lumbar vertebra, L5, which is normally unfused, can exhibit fusion. As you recall, fusion is a characteristic of sacral vertebrae.
     
    A Congenital Spine Abnormality
    This was the situation with our physician. His lowest lumbar vertebra, L5, has partially fused with S1, the highest sacral vertebra. This condition is congenital. He has had it all his life. The fusion can have the side effect of creating a very narrow bony canal through which the L5 nerve roots can exit the spine. Normally, these nerve roots would have much more space as a large gap would exist between the normally unfused L5 and S1 vertebrae. Was this the problem? The CT scan showed the sacralization of L5, but it was difficult to get a sense for how tight the holes through which the nerves exit, the neural foramina, were. See Figures 2 and 3.
     

     
    Figure 2: Coronal CT image through the L5 and S1 vertebral bodies. Is this the cause of the problem? It is very difficult to get an intuitive sense of what is going on with these flat image slices.
     

     
    Figure 3: Image from Figure 2 with the neural foramina marked.
     
    Seeking help through Embodi3D
    The doctor contacted me through the Embodi3D website and asked if I could create a 3D model design and 3D print of his lumbar spine to help him and his team of spinal specialists understand his unique anatomy better. Of course, I was happy to help. The CT scan was of high quality and allowed me to extract the bones and metallic spinal fusion implants with little trouble. The individual nerves, however, were very difficult to see even on a high quality CT scan. I had to manually segment them one image at a time, which was a very tedious and time-consuming process. After fusing everything together, I had a very good digital model of the lumbar spine. I created some photorealistic 3D renders to illustrate the key findings.
     
    Figures 4 and 5 show the very tight L5-S1 bony neural foramina. The inter-vertebral disc sits within the gap between the two vertebral bodies, and you can see how a lateral bulge from this disc would significantly pinch these exiting nerve roots.
     

     
    Figure 4: Right L5 nerve root (yellow) exiting the tight neural foramen caused by the fused L5 and S1 lateral processes.
     

     
    Figure 5: Left L5 nerve root (yellow) exiting the tight neural foramen caused by the fused L5 and S1 lateral processes.
     
    Additionally, I showed that a bone screw that had been placed during the last surgery had partially exited the L4 vertebral body and was in very close proximity, and probably touching, the adjacent nerve root. Ouch! This can be seen in Figure 6. This may explain why the pain seem to get worse after the last surgery.
     

     
    Figure 6: Transpedicular orthopedic screw which has partially exited the L4 vertebral body and is in very close proximity or in contact with the right L3 nerve root.
     
    The Final 3D Printed Spine Model
    The doctor wanted his spine 3D printed in transparent material, so I used a stereolithographic printer with transparent resin. I printed the spine in two separate parts that could be separated and fit together. When separated, the nerves exiting through the neural foramina can be inspected from inside the spinal canal, which gives an added degree of understanding.
     
    Final pictures of the transparent 3D printed model are shown below.
     
     

     

     
     

     
     

     
     

     
     
     
    I just recently shipped the model to this doctor and don't yet know how his back problems will be resolved. With this 3D printed model in hand however, he will be able to have much more meaningful discussions with his spinal surgeons about the best way to definitively fix his low back problems. I hope that the 3D printed spine model will literally help to get this good doctor back on his feet again.
  26. Like
    Dr. Mike got a reaction from cyruschow for a blog entry, 3D Printing a Spine Model to Help a Fellow Doctor with Low Back Pain   
    I was recently contacted by another doctor who asked if I could help him to create a 3D printed replicate of his spine to visualize pinched nerves in his low back and aid with planning a future back surgery. In order to work this doctor has to stand for long hours while performing surgical procedures. Excruciating low back pain had limited his ability to stand to only 30 minutes. As you can imagine, this means he couldn't work. Things only got worse after he had low back surgery.
     
    A CT scan of his lumbar spine (the low back portion of the spine) was performed. It showed that his fifth lumbar vertebra was partially sacralized. This means it looked more like a sacral vertebra than a lumbar vertebra. Was this causing his problem? On the image slices of the CT scan it was difficult to tell.
     
    How the Spine is Organized
    First, a word about the different vertebrae (bones) in the spine. There are four main sections of spinal bones. The seven cervical vertebrae are in the neck and support the head. They are generally small but flexible, and allow rotation of the head. The 12 thoracic vertebrae are in the chest. Their most distinctive characteristic is they all have associated ribs, which make up the rib cage. The five lumbar vertebrae are in the low back. These are large and strong, and designed for supporting lots of weight. They do not have associated ribs. The five sacral vertebrae are in the pelvis. In adults, they are fused together and effectively form a single bone, the sacrum. The coccyx, or tailbone, which is a tiny bone at the bottom end of the vertebral column, can be considered a fifth spinal section. This is the bone that is often injured when you fallen your behind. Figure 1 shows the different sections of the vertebral column.
     

    Figure 1. Sections of the vertebral column. Source:aimisspine.com
     
    Although the bones of the individual sections of the spine usually have their own unique features, it is not uncommon for vertebrae in one section to have features typically associated with an adjacent section. This is particularly true of the vertebrae that are immediately adjacent to a neighboring section. These hybrids are a mix between both sections, are called transitional vertebrae. Do you recall that only thoracic vertebrae have associated ribs? Occasionally the highest lumbar vertebra, L1, will have tiny ribs attached to it. This is a normal variant and is usually harmless. Radiologists who are interpreting medical scans need to be careful to not confuse an L1 vertebra which may have tiny ribs for the adjacent T12 vertebra which normally has ribs. Similarly, the lowest lumbar vertebra, L5, which is normally unfused, can exhibit fusion. As you recall, fusion is a characteristic of sacral vertebrae.
     
    A Congenital Spine Abnormality
    This was the situation with our physician. His lowest lumbar vertebra, L5, has partially fused with S1, the highest sacral vertebra. This condition is congenital. He has had it all his life. The fusion can have the side effect of creating a very narrow bony canal through which the L5 nerve roots can exit the spine. Normally, these nerve roots would have much more space as a large gap would exist between the normally unfused L5 and S1 vertebrae. Was this the problem? The CT scan showed the sacralization of L5, but it was difficult to get a sense for how tight the holes through which the nerves exit, the neural foramina, were. See Figures 2 and 3.
     

     
    Figure 2: Coronal CT image through the L5 and S1 vertebral bodies. Is this the cause of the problem? It is very difficult to get an intuitive sense of what is going on with these flat image slices.
     

     
    Figure 3: Image from Figure 2 with the neural foramina marked.
     
    Seeking help through Embodi3D
    The doctor contacted me through the Embodi3D website and asked if I could create a 3D model design and 3D print of his lumbar spine to help him and his team of spinal specialists understand his unique anatomy better. Of course, I was happy to help. The CT scan was of high quality and allowed me to extract the bones and metallic spinal fusion implants with little trouble. The individual nerves, however, were very difficult to see even on a high quality CT scan. I had to manually segment them one image at a time, which was a very tedious and time-consuming process. After fusing everything together, I had a very good digital model of the lumbar spine. I created some photorealistic 3D renders to illustrate the key findings.
     
    Figures 4 and 5 show the very tight L5-S1 bony neural foramina. The inter-vertebral disc sits within the gap between the two vertebral bodies, and you can see how a lateral bulge from this disc would significantly pinch these exiting nerve roots.
     

     
    Figure 4: Right L5 nerve root (yellow) exiting the tight neural foramen caused by the fused L5 and S1 lateral processes.
     

     
    Figure 5: Left L5 nerve root (yellow) exiting the tight neural foramen caused by the fused L5 and S1 lateral processes.
     
    Additionally, I showed that a bone screw that had been placed during the last surgery had partially exited the L4 vertebral body and was in very close proximity, and probably touching, the adjacent nerve root. Ouch! This can be seen in Figure 6. This may explain why the pain seem to get worse after the last surgery.
     

     
    Figure 6: Transpedicular orthopedic screw which has partially exited the L4 vertebral body and is in very close proximity or in contact with the right L3 nerve root.
     
    The Final 3D Printed Spine Model
    The doctor wanted his spine 3D printed in transparent material, so I used a stereolithographic printer with transparent resin. I printed the spine in two separate parts that could be separated and fit together. When separated, the nerves exiting through the neural foramina can be inspected from inside the spinal canal, which gives an added degree of understanding.
     
    Final pictures of the transparent 3D printed model are shown below.
     
     

     

     
     

     
     

     
     

     
     
     
    I just recently shipped the model to this doctor and don't yet know how his back problems will be resolved. With this 3D printed model in hand however, he will be able to have much more meaningful discussions with his spinal surgeons about the best way to definitively fix his low back problems. I hope that the 3D printed spine model will literally help to get this good doctor back on his feet again.
  27. Like
    Dr. Mike got a reaction from vlad for a blog entry, 3D Printing of Bones from CT Scans: A Tutorial on Quickly Correcting Extensive Mesh Errors using Blender and MeshMixer   
    Hello and welcome back. Once again, I am Dr. Mike, board-certified radiologist and 3D printing enthusiast. Today I'm going to show you how to correct severe mesh defects in a bone model generated from a CT scan. This will be in preparation for 3D printing. I'll be using the free software programs Blender and Meshmixer.
    In my last medical 3d printing video tutorial, I showed you how to remove extraneous mesh within the medullary cavity of a bone. That technique is best used when mesh defects are limited. In instances where mesh defects in a bony model are severe and extensive, a different approach is needed. In this video, I'll show you how to correct extensive mesh errors in bony anatomical models using Blender and Meshmixer. This assumes that you know how to generate a basic STL file from a CT scan. There are a variety of commercial and freeware products that allow you to do this, on a variety of platforms. If you don't yet know how to do this, stay tuned, as I have a series of tutorials planned which will show you how to do this on a variety of operating systems and budgets.
    If you wish to follow along with this tutorial, you can download the free tutorial file pack by clicking this link. This is highly recommended, as the files allow you to follow along with the tutorial, which will make learning easier. Included is the STL file used in this tutorial. Also, a powerful Blender script is included which will enable you to easily and efficiently prepare your own bone models for 3D printing. It's a real timesaver. If you haven't registered at Embodi3D.com, registration is free and only takes a moment.
    DOWNLOAD THE ACCOMPANYING FILE PACK. CLICK HERE.
    You can watch the video tutorial for a quick overview, or read this article for a detailed description.
    Initial analysis using Meshmixer
    Let's take a look at an STL file of a talus fracture in the ankle. This 3D model is from a real patient who suffered a fracture of the talus. The talus is the bone in the ankle that the tibia, or shinbone, sits on. This STL file is included in the file pack. Let's open this file in Meshmixer (Figure 1). Meshmixer is free software published by Autodesk, a leading maker of engineering software. If you don't have Meshmixer, you can go to Meshmixer.com and download it for free.

    Figure 1
    Once you have the file open in Meshmixer, click on the Analysis button and select Inspector. The inspector shows all the errors in this mesh. Blue parts represent holes in the mesh. Red parts show areas where the mesh is non-manifold. Magenta parts show disconnected components. As you can see, there are a lot of problems with this mesh, and it is not suitable for 3D printing in its current state (Figure 2).

    Figure 2
    Meshmixer has a feature to automatically repair these mesh defects. However, there are so many problems with this mesh that the auto repair function fails. Click on the Auto Repair All button. Meshmixer has tried to repair these mesh defects, and has successfully reduced the number of defects. However, it is also introduced gaping holes in the model. Entire bones are missing (Figure 3). This clearly isn't the desired outcome.

    Figure 3
    Opening the STL file in Blender
    The solution to this problem can be found with Blender. Blender is a free, open-source software package that is primarily designed for animation. It is so feature-rich however, that it can be used for a variety of different purposes, and increasingly is being used for tasks related to 3D printing. If you don't have Blender, you can download it from blender.org. At the time of this writing, the current version is 2.73 a.
    Open up Blender. Go ahead and delete the default cube shown in the middle of the screen (Figure 4) by right clicking it and hitting the "X" key followed by the "D" key. If you are new to Blender, you'll soon learn that much of what you can do with Blender can be done with keyboard shortcuts. This can be daunting to learn for beginners, but makes use of Blender very efficient for heavy users.

    Figure 4
    Next open the STL file in Blender. Go to the File menu in the upper left, select Import, and select "Stl (.stl)." Then, navigate to the folder for the tutorial files and select the "ankle - talus fracture.stl" file. You probably don't see anything, as is shown in Figure 5. To understand how this happens, you need to know a little bit about how Blender measures distances. Blender uses an arbitrary measure of distance called a "blender unit." One blender unit is equivalent to one of the little squares seen in the viewport. However, in real life distances are measured in real units, such as feet, inches, centimeters, and millimeters. Most STL files that are generated from medical imaging data have default unit of measurement of millimeters. When Blender imports the file it converts the millimeter units to blender units. Since our imported model is the size of human foot, measuring 240 mm or so, the model will be 240 blender units, or 240 of those little squares, in length. We can't see it because the model is too big! Our viewport is zoomed into much! Zoom out using the mouse wheel way, way back until you can see the model as shown in Figure 6.

    Figure 5: Where is the model?

    Figure 6: There it is!
    Correcting the Object Origin
    You will notice that the origin of the ankle object, as shown by the red blue and green axes (Figure 6), is actually outside of object itself. Left uncorrected, this can be a really annoying issue. When you rotate or pan around the object, you will rotate or pan around these three axes, instead of the ankle object itself. Fortunately, correcting this takes only a moment. In the lower left-hand part of the window select the Object menu. Be sure that you have the ankle object selected first. Then choose Transform, Geometry to Origin. The ankle object is then moved to the red blue and green axes. With the object origin now in the center of the mesh, the mesh will be much easier to work with.

    Figure 7: The ankle mesh and object origin are now aligned.
    Inspect the ankle mesh
    If you look closely at the ankle mesh you can see immediately that it has a lot of problems. In the solid shader mode, the bones look very faceted. The polygons are large, giving the bones a unnatural appearance (Figure 8). Don't worry, will fix this. If you turn on wireframe mode by hitting the "Z" key you can see that there is a lot of extraneous mesh within the bones that represents unwanted mesh from the medullary cavities of these bones (Figure 9). Furthermore, if you check for non-manifold mesh by holding control-shift-alt-M, you'll see that there are innumerable non-manifold mesh defects (Figure 10).

    Figure 8: Note the very faceted appearance of the bones.

    Figure 9: There is a significant amount of unneeded and extraneous mesh, particularly within the medullary cavities of the bones.

    Figure 10: Non-manifold mesh defects.
    If you are unfamiliar with the term "non-manifold," let me take a moment to explain. A mesh is simply a surface. It is infinitely thin. If the mesh is continuous and unbroken, and has a contained volume within it, then the mesh can be considered to represent something solid. In this case, the mesh surface represents the interface between the inside of the object and the outside of the object, such as the sphere shown in Figure 11. An object like this is considered to be "manifold," or watertight. It represents a solid that can really exist in the physical world, and can thus be 3D printed.

    Figure 11
    If however, I cut a hole in the sphere, as shown in Figure 12, then there is a gap in the mesh. A 3D printer won't know what to do with this. Is this supposed to be solid like a ball, or hollow like a cup? If it is supposed to be like a cup, how thick are the walls supposed to be? The walls in this mesh are infinitesimally thin, so what is the correct thickness? This mesh is not watertight - that is, should water be placed in the structure it would leak out. The mesh is non-manifold. It cannot be 3D printed. If we use the control-shift-alt-M sequence to highlight non-manifold mesh, as shown in Figure 13, we can see that Blender correctly identifies the edge of the hole as having non-manifold mesh.

    Figure 12

    Figure 13
    Closing major holes manually in Blender
    In this particular mesh, there are many, many small mesh errors and two very large ones. The distal tibia and fibula bones have been cut off by the CT scanner, leaving gaping holes in the mesh as shown in Figure 14. Fixing these manually will only take a moment and make things easier down the road, so let's take care of that now. Enter Edit mode by hitting the Tab key, or clicking it in the Mode menu. If you hit control-shift-alt-M to select non-manifold edges, you can clearly see that these bone cuts are a problem as shown in Figure 15.

    Figure 14

    Figure 15
    Go to Vertex selection mode by clicking the vertex button or hitting control-tab-1 on the keyboard as shown in Figure 16. Select one of the vertices from the medullary portion of the tibia bone as shown in Figure 17. This mesh represents the medullary cavity of the tibia bone, and is not connected to the rest of the mesh. Hit control-L to select all contiguous vertices (Figure 18). All the unwanted medullary cavity mesh should now be highlighted. Delete this by hitting the "X" key followed by the "V" key, or by hitting the delete and selecting "vertices." There is another small bit of medullary cavity mesh at the edge of the tibia cut. Perform the same routine and delete this as well.

    Figure 16

    Figure 17

    Figure 18
    Next we will direct our attention to the unwanted medullary mesh of the thinner fibula bone. Click on a vertex in the fibula medullary mesh and hit control L. You will note that the entire mesh is highlighted as shown in Figure 19. This indicates that the medullary mesh is connected to the rest of the mesh in some way. We don't need to manually delete all of the medullary mesh. We just need to get it away from the edge where we will create a new face to close the bone edges. Go to Edge selection mode by hitting control-tab-2 or clicking the edge selection button as shown in Figure 20. Hit the "A" key to unselect everything. Then, click on a single edge along the unwanted medullary mesh, as shown in Figure 21.

    Figure 19

    Figure 20

    Figure 21
    Next we will by holding down the alt key and right clicking on the edge again. Blender should select the loop around the entire edge as shown in Figure 22. We will now expand the selection by holding down the control tab and hitting the plus key on the number pad. Hit the plus key three times. Your selection should now look like that in Figure 23. Delete the highlighted mesh by hitting the "X" and "V" keys, or hitting the delete key and selecting vertices.

    Figure 22

    Figure 23
    Next we are going to close the holes by holding down the alt key and right clicking along the edge of the cut line of the fibula. An entire loop should be selected as shown in Figure 24. Create a face by hitting the "F" key. Convert to triangles by hitting Control-T. The end of the fibula should be closed, as shown in Figure 25. Repeat the same for the open edge of the tibia bone. Afterwards the mesh should look as it does and Figure 26.

    Figure 24

    Figure 25

    Figure 26
    Creating a Shell of the model using the Shrinkwrap and Remesh modifiers in Blender
    So how will it ever be possible to correct the hundreds and hundreds of mesh errors in the ankle model? This is the million-dollar question. A mesh of this complexity often cannot be fixed using automated mesh correction software, as we saw with Meshmixer. Correcting this many errors manually is a time-consuming and tedious process. I've spent hundreds of hours correcting mesh errors like this one by one. But, after years of creating 3D printable anatomical models, I've developed a technique to fix these mesh errors in only a few minutes.
    The secret is this: You don't fix the mesh errors. Leave them alone. You create a new mesh to replace them!
    Let's start by creating a sphere. If you are in Edit mode, exit that by hitting the Tab key. If you are still in wireframe viewport mode, hit the "Z" key to return to solid viewport shading. In the lower left-hand side of the window, hit the Add menu. Select Mesh, UV sphere and add a sphere. An "Add UV Sphere" panel will show up on the left side of your screen as shown in Figure 27. We want the sphere to have lots of detail. Under Segments enter 256. Under Rings, enter 128. The default size of the sphere is only one blender unit (1 mm) in size. This is too small, we want the thing to be huge. Enter 1000 for size. At this point you should have a very large sphere surrounding your entire scene. Believe it or not, this sphere will eventually be your new ankle object. Let's go ahead and rename it "Ankle skin" as shown in Figure 29.

    Figure 27: Add a UV sphere

    Figure 28: Configure the sphere. Segments 256, rings 128, size 1000

    Figure 29: Rename the sphere to "Ankle skin"
    Applying the Shrinkwrap Modifier
    Select the "Ankle skin" object. Click on the Modifiers tab, it looks like a small wrench (Figure 30). From the Ad Modifier drop-down menu, select the Shrinkwrap item. Specify the Ankle object as "the target. Set off set to 0.5. Check the" Keep Above Surface" box. Your sphere will have shrunken down to envelop the ankle, as shown in Figure 30. Apply the modifier by hitting the "Apply" button. At this point you're thinking that your Ankle skin object hardly looks like an ankle, and you're right. If you try to apply the shrinkwrap modifier again, you won't get any change in the mesh. Blender has shrunken the sphere as best it can given the limited geometry of the sphere. To go further we need to change the geometry a bit, which is where the Remesh modifier comes in.

    Figure 30: The Shrinkwrap modifier
    Applying the Remesh Modifier
    Next go to Add Modifier again, and select Remesh. Set Mode to Smooth, Octree Depth = 8, and uncheck Remove Disconnected Pieces. By now you should have something that looks like Figure 31. Apply the modifier by clicking the Apply button.

    Figure 31: The Remesh modifier
    Apply the Shrinkwrap Modifier again
    Apply the shrinkwrap modifier again, using the same parameters as before. Your Ankle skin object should look like Figure 32. Now we are getting somewhere! There is still a long way to go, but the mesh somewhat resembles the bones of the foot. By repeatedly applying the Shrinkwrap and Remesh modifiers the Ankle skin object, which was originally a sphere, will slowly approximate the surface of the error-filled original ankle mesh. Because of the original skin was a sphere, and hence manifold, as it is shrink-wrapped around the ankle mesh it will preserve (for the most part) it's mesh integrity. There will be no unnecessary internal geometry. Any holes or other defects in the original mesh will be covered. Unfortunately, repeatedly applying the shrinkwrap and remesh modifier again and again is somewhat tedious (although not as tedious as manually correcting all the errors in the original mesh). Fortunately, we can automate this process using Python scripting. This allows us to create a new mesh in a matter of minutes.

    Figure 32
    Automating the Shrinkwrap Process using Python Scripting
    For those of you less familiar with Blender's more advanced features, you may be surprised to learn that it is fully scriptable. That means that you can program it to perform tasks repeatedly using a Python script. In this case we want to repeatedly execute shrinkwrap and remesh modifiers on our ankle skin object. With each iteration the skin will more closely approximate the surface of the original mesh. If you are familiar with Python scripting, you can write a script yourself to call the necessary modifiers and specify the necessary variables. To make things easier for you, I have written a Python script for you. It is included in the free tutorial file pack.
    Change the bottom window to the text editor. View button in the bottom left-hand corner as shown in Figure 33. Select Text Editor. Click on the "Open" button and navigate to the folder with the tutorial file pack files as shown in Figure 34. Double-click on the "shrinkwrap loop.txt" file as shown in Figure 35.

    Figure 33: Select the text editor

    Figure 34: Click on the Open button

    Figure 35: Open the "shrinkwrap loop.txt" file
    The script file should now open in the text editor window. Adjust the target_object variable to be the target you want your skin wrapped around, in this case the "Ankle - Talus Fracture" object. Leave the shrinkwrap_offset variable at 0.5 for now. You can specify how many shrinkwrap-remesh iterations you want to run. For now leave it at 20. Click the "Run Script" button as shown in Figure 36. The script will now run, and it will apply the shrinkwrap-remesh modifiers 20 times. On my machine it takes about one minute for the script to execute.

    Figure 36
    At this point you'll notice that the ankle skin object very closely approximates the original ankle object, as shown in Figure 37. Run the script again using the same settings. At this point the mesh is really looking pretty good. Let's run the script a final time with the smaller offset to more closely approximate the real bones. Set the shrinkwrap_offset variable to 0.3 and run the script again reducing iterations to 10. After completion the mesh should appear as it does in Figure 38. If you compare our new skin mesh as shown in Figure 39 (left) to the original ankle object in Figure 39 (right) you can see that our new skin is actually much more realistic than the original mesh. The highly faceted appearance of the original mesh has been replaced by a smoothed appearance of our shrink-wrapped skin. Furthermore, whereas the original mesh actually had separate bones that were disconnected, the new, shrink-wrapped mesh is a single interconnected object. From a 3D printing standpoint this is much better as the ankle bones will print together as a single unit

    Figure 37

    Figure 38

    Figure 39: Comparison of original plus new shrink-wrapped mesh.
    Finalizing the Ankle Model for 3D printing using Meshmixer.
    Select the new ankle object. Export the object to the STL file format. From the file menu select Export and then "Stl (.stl)." Let's call the file "ankle corrected.STL." Open the new STL file in Meshmixer. You will notice that Meshmixer immediately identifies some mesh errors as shown in Figure 40. This is because the Remesh modifier in Blender occasionally introduces non-manifold mesh defects. You will note however that the number of defect is significantly less than our original model which was shown in Figure 1. With this smaller number of errors, Meshmixer can fix them automatically. Go to the Analysis button and select Inspector. Meshmixer will highlight the individual mesh defects, as shown in Figure 41. Click on the "Auto Repair All" button. Meshmixer will then automatically repair the mesh defects. The result is shown in Figure 42.

    Figure 40

    Figure 41: Meshmixer inspector

    Figure 42: Corrected mesh
    The mesh looks great, and is ready for 3D printing! Export the STL file by going to the File menu in Meshmixer and selecting Export. Save the file as "ankle final result.STL".
    Please share with the community.
    If you have found this tutorial helpful and are actively creating 3D printable anatomic models, please consider sharing your work with the Embodi3D community. You can share your models in the File Vault. If you have comments or advice, you can share your expertise in the Forums. If you are interested in blogging about your adventures in medical 3D printing, contact me or one of the administrators and we can set up blogging on your Embodi3D user account. If you wish to hire someone to help you with your anatomical 3D printing project, you can place an ad for free in the Services Needed Forum, If you are doing your own anatomical 3D printing and are willing to help others, list your services for free in the Services Offered Forum.
    This is a community. We are all helping each other. Please consider giving back if you can.
    Have fun 3D printing!
  28. Like
    Dr. Mike got a reaction from cjd2 for a blog entry, 3D Printing of Bones from CT Scans: A Tutorial on Quickly Correcting Extensive Mesh Errors using Blender and MeshMixer   
    Hello and welcome back. Once again, I am Dr. Mike, board-certified radiologist and 3D printing enthusiast. Today I'm going to show you how to correct severe mesh defects in a bone model generated from a CT scan. This will be in preparation for 3D printing. I'll be using the free software programs Blender and Meshmixer.
    In my last medical 3d printing video tutorial, I showed you how to remove extraneous mesh within the medullary cavity of a bone. That technique is best used when mesh defects are limited. In instances where mesh defects in a bony model are severe and extensive, a different approach is needed. In this video, I'll show you how to correct extensive mesh errors in bony anatomical models using Blender and Meshmixer. This assumes that you know how to generate a basic STL file from a CT scan. There are a variety of commercial and freeware products that allow you to do this, on a variety of platforms. If you don't yet know how to do this, stay tuned, as I have a series of tutorials planned which will show you how to do this on a variety of operating systems and budgets.
    If you wish to follow along with this tutorial, you can download the free tutorial file pack by clicking this link. This is highly recommended, as the files allow you to follow along with the tutorial, which will make learning easier. Included is the STL file used in this tutorial. Also, a powerful Blender script is included which will enable you to easily and efficiently prepare your own bone models for 3D printing. It's a real timesaver. If you haven't registered at Embodi3D.com, registration is free and only takes a moment.
    DOWNLOAD THE ACCOMPANYING FILE PACK. CLICK HERE.
    You can watch the video tutorial for a quick overview, or read this article for a detailed description.
    Initial analysis using Meshmixer
    Let's take a look at an STL file of a talus fracture in the ankle. This 3D model is from a real patient who suffered a fracture of the talus. The talus is the bone in the ankle that the tibia, or shinbone, sits on. This STL file is included in the file pack. Let's open this file in Meshmixer (Figure 1). Meshmixer is free software published by Autodesk, a leading maker of engineering software. If you don't have Meshmixer, you can go to Meshmixer.com and download it for free.

    Figure 1
    Once you have the file open in Meshmixer, click on the Analysis button and select Inspector. The inspector shows all the errors in this mesh. Blue parts represent holes in the mesh. Red parts show areas where the mesh is non-manifold. Magenta parts show disconnected components. As you can see, there are a lot of problems with this mesh, and it is not suitable for 3D printing in its current state (Figure 2).

    Figure 2
    Meshmixer has a feature to automatically repair these mesh defects. However, there are so many problems with this mesh that the auto repair function fails. Click on the Auto Repair All button. Meshmixer has tried to repair these mesh defects, and has successfully reduced the number of defects. However, it is also introduced gaping holes in the model. Entire bones are missing (Figure 3). This clearly isn't the desired outcome.

    Figure 3
    Opening the STL file in Blender
    The solution to this problem can be found with Blender. Blender is a free, open-source software package that is primarily designed for animation. It is so feature-rich however, that it can be used for a variety of different purposes, and increasingly is being used for tasks related to 3D printing. If you don't have Blender, you can download it from blender.org. At the time of this writing, the current version is 2.73 a.
    Open up Blender. Go ahead and delete the default cube shown in the middle of the screen (Figure 4) by right clicking it and hitting the "X" key followed by the "D" key. If you are new to Blender, you'll soon learn that much of what you can do with Blender can be done with keyboard shortcuts. This can be daunting to learn for beginners, but makes use of Blender very efficient for heavy users.

    Figure 4
    Next open the STL file in Blender. Go to the File menu in the upper left, select Import, and select "Stl (.stl)." Then, navigate to the folder for the tutorial files and select the "ankle - talus fracture.stl" file. You probably don't see anything, as is shown in Figure 5. To understand how this happens, you need to know a little bit about how Blender measures distances. Blender uses an arbitrary measure of distance called a "blender unit." One blender unit is equivalent to one of the little squares seen in the viewport. However, in real life distances are measured in real units, such as feet, inches, centimeters, and millimeters. Most STL files that are generated from medical imaging data have default unit of measurement of millimeters. When Blender imports the file it converts the millimeter units to blender units. Since our imported model is the size of human foot, measuring 240 mm or so, the model will be 240 blender units, or 240 of those little squares, in length. We can't see it because the model is too big! Our viewport is zoomed into much! Zoom out using the mouse wheel way, way back until you can see the model as shown in Figure 6.

    Figure 5: Where is the model?

    Figure 6: There it is!
    Correcting the Object Origin
    You will notice that the origin of the ankle object, as shown by the red blue and green axes (Figure 6), is actually outside of object itself. Left uncorrected, this can be a really annoying issue. When you rotate or pan around the object, you will rotate or pan around these three axes, instead of the ankle object itself. Fortunately, correcting this takes only a moment. In the lower left-hand part of the window select the Object menu. Be sure that you have the ankle object selected first. Then choose Transform, Geometry to Origin. The ankle object is then moved to the red blue and green axes. With the object origin now in the center of the mesh, the mesh will be much easier to work with.

    Figure 7: The ankle mesh and object origin are now aligned.
    Inspect the ankle mesh
    If you look closely at the ankle mesh you can see immediately that it has a lot of problems. In the solid shader mode, the bones look very faceted. The polygons are large, giving the bones a unnatural appearance (Figure 8). Don't worry, will fix this. If you turn on wireframe mode by hitting the "Z" key you can see that there is a lot of extraneous mesh within the bones that represents unwanted mesh from the medullary cavities of these bones (Figure 9). Furthermore, if you check for non-manifold mesh by holding control-shift-alt-M, you'll see that there are innumerable non-manifold mesh defects (Figure 10).

    Figure 8: Note the very faceted appearance of the bones.

    Figure 9: There is a significant amount of unneeded and extraneous mesh, particularly within the medullary cavities of the bones.

    Figure 10: Non-manifold mesh defects.
    If you are unfamiliar with the term "non-manifold," let me take a moment to explain. A mesh is simply a surface. It is infinitely thin. If the mesh is continuous and unbroken, and has a contained volume within it, then the mesh can be considered to represent something solid. In this case, the mesh surface represents the interface between the inside of the object and the outside of the object, such as the sphere shown in Figure 11. An object like this is considered to be "manifold," or watertight. It represents a solid that can really exist in the physical world, and can thus be 3D printed.

    Figure 11
    If however, I cut a hole in the sphere, as shown in Figure 12, then there is a gap in the mesh. A 3D printer won't know what to do with this. Is this supposed to be solid like a ball, or hollow like a cup? If it is supposed to be like a cup, how thick are the walls supposed to be? The walls in this mesh are infinitesimally thin, so what is the correct thickness? This mesh is not watertight - that is, should water be placed in the structure it would leak out. The mesh is non-manifold. It cannot be 3D printed. If we use the control-shift-alt-M sequence to highlight non-manifold mesh, as shown in Figure 13, we can see that Blender correctly identifies the edge of the hole as having non-manifold mesh.

    Figure 12

    Figure 13
    Closing major holes manually in Blender
    In this particular mesh, there are many, many small mesh errors and two very large ones. The distal tibia and fibula bones have been cut off by the CT scanner, leaving gaping holes in the mesh as shown in Figure 14. Fixing these manually will only take a moment and make things easier down the road, so let's take care of that now. Enter Edit mode by hitting the Tab key, or clicking it in the Mode menu. If you hit control-shift-alt-M to select non-manifold edges, you can clearly see that these bone cuts are a problem as shown in Figure 15.

    Figure 14

    Figure 15
    Go to Vertex selection mode by clicking the vertex button or hitting control-tab-1 on the keyboard as shown in Figure 16. Select one of the vertices from the medullary portion of the tibia bone as shown in Figure 17. This mesh represents the medullary cavity of the tibia bone, and is not connected to the rest of the mesh. Hit control-L to select all contiguous vertices (Figure 18). All the unwanted medullary cavity mesh should now be highlighted. Delete this by hitting the "X" key followed by the "V" key, or by hitting the delete and selecting "vertices." There is another small bit of medullary cavity mesh at the edge of the tibia cut. Perform the same routine and delete this as well.

    Figure 16

    Figure 17

    Figure 18
    Next we will direct our attention to the unwanted medullary mesh of the thinner fibula bone. Click on a vertex in the fibula medullary mesh and hit control L. You will note that the entire mesh is highlighted as shown in Figure 19. This indicates that the medullary mesh is connected to the rest of the mesh in some way. We don't need to manually delete all of the medullary mesh. We just need to get it away from the edge where we will create a new face to close the bone edges. Go to Edge selection mode by hitting control-tab-2 or clicking the edge selection button as shown in Figure 20. Hit the "A" key to unselect everything. Then, click on a single edge along the unwanted medullary mesh, as shown in Figure 21.

    Figure 19

    Figure 20

    Figure 21
    Next we will by holding down the alt key and right clicking on the edge again. Blender should select the loop around the entire edge as shown in Figure 22. We will now expand the selection by holding down the control tab and hitting the plus key on the number pad. Hit the plus key three times. Your selection should now look like that in Figure 23. Delete the highlighted mesh by hitting the "X" and "V" keys, or hitting the delete key and selecting vertices.

    Figure 22

    Figure 23
    Next we are going to close the holes by holding down the alt key and right clicking along the edge of the cut line of the fibula. An entire loop should be selected as shown in Figure 24. Create a face by hitting the "F" key. Convert to triangles by hitting Control-T. The end of the fibula should be closed, as shown in Figure 25. Repeat the same for the open edge of the tibia bone. Afterwards the mesh should look as it does and Figure 26.

    Figure 24

    Figure 25

    Figure 26
    Creating a Shell of the model using the Shrinkwrap and Remesh modifiers in Blender
    So how will it ever be possible to correct the hundreds and hundreds of mesh errors in the ankle model? This is the million-dollar question. A mesh of this complexity often cannot be fixed using automated mesh correction software, as we saw with Meshmixer. Correcting this many errors manually is a time-consuming and tedious process. I've spent hundreds of hours correcting mesh errors like this one by one. But, after years of creating 3D printable anatomical models, I've developed a technique to fix these mesh errors in only a few minutes.
    The secret is this: You don't fix the mesh errors. Leave them alone. You create a new mesh to replace them!
    Let's start by creating a sphere. If you are in Edit mode, exit that by hitting the Tab key. If you are still in wireframe viewport mode, hit the "Z" key to return to solid viewport shading. In the lower left-hand side of the window, hit the Add menu. Select Mesh, UV sphere and add a sphere. An "Add UV Sphere" panel will show up on the left side of your screen as shown in Figure 27. We want the sphere to have lots of detail. Under Segments enter 256. Under Rings, enter 128. The default size of the sphere is only one blender unit (1 mm) in size. This is too small, we want the thing to be huge. Enter 1000 for size. At this point you should have a very large sphere surrounding your entire scene. Believe it or not, this sphere will eventually be your new ankle object. Let's go ahead and rename it "Ankle skin" as shown in Figure 29.

    Figure 27: Add a UV sphere

    Figure 28: Configure the sphere. Segments 256, rings 128, size 1000

    Figure 29: Rename the sphere to "Ankle skin"
    Applying the Shrinkwrap Modifier
    Select the "Ankle skin" object. Click on the Modifiers tab, it looks like a small wrench (Figure 30). From the Ad Modifier drop-down menu, select the Shrinkwrap item. Specify the Ankle object as "the target. Set off set to 0.5. Check the" Keep Above Surface" box. Your sphere will have shrunken down to envelop the ankle, as shown in Figure 30. Apply the modifier by hitting the "Apply" button. At this point you're thinking that your Ankle skin object hardly looks like an ankle, and you're right. If you try to apply the shrinkwrap modifier again, you won't get any change in the mesh. Blender has shrunken the sphere as best it can given the limited geometry of the sphere. To go further we need to change the geometry a bit, which is where the Remesh modifier comes in.

    Figure 30: The Shrinkwrap modifier
    Applying the Remesh Modifier
    Next go to Add Modifier again, and select Remesh. Set Mode to Smooth, Octree Depth = 8, and uncheck Remove Disconnected Pieces. By now you should have something that looks like Figure 31. Apply the modifier by clicking the Apply button.

    Figure 31: The Remesh modifier
    Apply the Shrinkwrap Modifier again
    Apply the shrinkwrap modifier again, using the same parameters as before. Your Ankle skin object should look like Figure 32. Now we are getting somewhere! There is still a long way to go, but the mesh somewhat resembles the bones of the foot. By repeatedly applying the Shrinkwrap and Remesh modifiers the Ankle skin object, which was originally a sphere, will slowly approximate the surface of the error-filled original ankle mesh. Because of the original skin was a sphere, and hence manifold, as it is shrink-wrapped around the ankle mesh it will preserve (for the most part) it's mesh integrity. There will be no unnecessary internal geometry. Any holes or other defects in the original mesh will be covered. Unfortunately, repeatedly applying the shrinkwrap and remesh modifier again and again is somewhat tedious (although not as tedious as manually correcting all the errors in the original mesh). Fortunately, we can automate this process using Python scripting. This allows us to create a new mesh in a matter of minutes.

    Figure 32
    Automating the Shrinkwrap Process using Python Scripting
    For those of you less familiar with Blender's more advanced features, you may be surprised to learn that it is fully scriptable. That means that you can program it to perform tasks repeatedly using a Python script. In this case we want to repeatedly execute shrinkwrap and remesh modifiers on our ankle skin object. With each iteration the skin will more closely approximate the surface of the original mesh. If you are familiar with Python scripting, you can write a script yourself to call the necessary modifiers and specify the necessary variables. To make things easier for you, I have written a Python script for you. It is included in the free tutorial file pack.
    Change the bottom window to the text editor. View button in the bottom left-hand corner as shown in Figure 33. Select Text Editor. Click on the "Open" button and navigate to the folder with the tutorial file pack files as shown in Figure 34. Double-click on the "shrinkwrap loop.txt" file as shown in Figure 35.

    Figure 33: Select the text editor

    Figure 34: Click on the Open button

    Figure 35: Open the "shrinkwrap loop.txt" file
    The script file should now open in the text editor window. Adjust the target_object variable to be the target you want your skin wrapped around, in this case the "Ankle - Talus Fracture" object. Leave the shrinkwrap_offset variable at 0.5 for now. You can specify how many shrinkwrap-remesh iterations you want to run. For now leave it at 20. Click the "Run Script" button as shown in Figure 36. The script will now run, and it will apply the shrinkwrap-remesh modifiers 20 times. On my machine it takes about one minute for the script to execute.

    Figure 36
    At this point you'll notice that the ankle skin object very closely approximates the original ankle object, as shown in Figure 37. Run the script again using the same settings. At this point the mesh is really looking pretty good. Let's run the script a final time with the smaller offset to more closely approximate the real bones. Set the shrinkwrap_offset variable to 0.3 and run the script again reducing iterations to 10. After completion the mesh should appear as it does in Figure 38. If you compare our new skin mesh as shown in Figure 39 (left) to the original ankle object in Figure 39 (right) you can see that our new skin is actually much more realistic than the original mesh. The highly faceted appearance of the original mesh has been replaced by a smoothed appearance of our shrink-wrapped skin. Furthermore, whereas the original mesh actually had separate bones that were disconnected, the new, shrink-wrapped mesh is a single interconnected object. From a 3D printing standpoint this is much better as the ankle bones will print together as a single unit

    Figure 37

    Figure 38

    Figure 39: Comparison of original plus new shrink-wrapped mesh.
    Finalizing the Ankle Model for 3D printing using Meshmixer.
    Select the new ankle object. Export the object to the STL file format. From the file menu select Export and then "Stl (.stl)." Let's call the file "ankle corrected.STL." Open the new STL file in Meshmixer. You will notice that Meshmixer immediately identifies some mesh errors as shown in Figure 40. This is because the Remesh modifier in Blender occasionally introduces non-manifold mesh defects. You will note however that the number of defect is significantly less than our original model which was shown in Figure 1. With this smaller number of errors, Meshmixer can fix them automatically. Go to the Analysis button and select Inspector. Meshmixer will highlight the individual mesh defects, as shown in Figure 41. Click on the "Auto Repair All" button. Meshmixer will then automatically repair the mesh defects. The result is shown in Figure 42.

    Figure 40

    Figure 41: Meshmixer inspector

    Figure 42: Corrected mesh
    The mesh looks great, and is ready for 3D printing! Export the STL file by going to the File menu in Meshmixer and selecting Export. Save the file as "ankle final result.STL".
    Please share with the community.
    If you have found this tutorial helpful and are actively creating 3D printable anatomic models, please consider sharing your work with the Embodi3D community. You can share your models in the File Vault. If you have comments or advice, you can share your expertise in the Forums. If you are interested in blogging about your adventures in medical 3D printing, contact me or one of the administrators and we can set up blogging on your Embodi3D user account. If you wish to hire someone to help you with your anatomical 3D printing project, you can place an ad for free in the Services Needed Forum, If you are doing your own anatomical 3D printing and are willing to help others, list your services for free in the Services Offered Forum.
    This is a community. We are all helping each other. Please consider giving back if you can.
    Have fun 3D printing!
×
×
  • Create New...