an embodiment of the image guided system of u . s . pat . no . 6 , 285 , 902 teaches a system for placing distal interlocking screws in an im rod . as shown in fig1 , the system is based on a computer ( 121 ) that receives input from an x - ray imaging device ( 110 ) and a localizing device ( 120 ), and displays surgical instrument representations ( 123 ) over x - ray images ( 125 and 126 ) in real time . a tracked adapter ( 129 ) is attached to the exposed end of the inserted im rod ( 130 ) such that the pose of the rod can be tracked . a drill guide ( 128 ) is also tracked , and a representation of its trajectory ( 123 ) is overlaid on x - ray images ( 125 and 126 ) of the im rod ( 130 ). additionally , the system displays , in a separate window ( 127 ), the drill guide trajectory ( 123 ) relative to a graphical representation ( 124 ) of a cross - section of the im rod ( 130 ) at the level of the transverse interlocking holes ( 131 ) by projecting models of these instruments onto a picture plane ( 138 ). during the procedure , the surgeon uses the ap image ( 126 ) of the im rod ( 130 ) to align the drill guide ( 128 ) in the coronal plane , and the lateral image ( 125 ) and the cross sectional graphic ( 124 ) to align the drill guide ( 128 ) in the axial plane . the current invention improves upon the previous invention by providing greater accuracy in generating the graphic representations ( 124 ) of the im rod ( 130 ) relative to the drill guide ( 128 ), regardless of bending of the im rod ( 130 ) or minor errors in attaching the adapter ( 129 ) to the im rod ( 130 ). this improvement allows the surgeon to use these relative graphic representations ( 124 and 123 ) alone to exactly align the drill guide ( 128 ) in the axial plane . while the surgeon still uses the ap view ( 126 ) to align the drill guide ( 128 ) in the coronal plane , there is no longer a need to rely on the lateral view ( 125 ), thus avoiding the difficulty of positioning a drill guide ( 128 ) using an “ end - on ” representation , during the axial alignment of the trajectory . it also eliminates the need for the surgeon to estimate the required anteroposterior position of the drill guide tip based on the distance between the im rod and the femoral shaft cortex and the amount of axial rotation of the im rod . in the preferred embodiment , the im rod ( 130 ) is inserted in the long bone ( 133 ) in the usual manner . while the invention will be preferably described for drilling holes in the bone ( 133 ) for the interlocking holes ( 131 ) in the end of the im rod farthest from the exposed end , the system may be alternately used for all interlocking screws and associated implants . as shown in fig2 , a tracking device ( 129 ), preferably comprising an adapter ( 136 ) to the im rod ( 130 ) and an array of three or more localizing emitters ( 137 ), is attached to the exposed end of the im rod ( 130 ). the exposed end of the im rod ( 130 ) is keyed to the adapter ( 136 ) such that the adapter ( 136 ) is attached to the inserted rod in a unique manner and the relationship is known within the limits of error of attachment preferably to within a few degrees and a few millimeters . a coordinate frame , a , is defined preferably at the interface between the im rod ( 130 ) and the tracking device ( 129 ) and is in a known and fixed relationship to the localizing emitters ( 137 ). computer models of the features of the tracking adapter ( 129 ) and im rod relative to coordinate frame a and graphic representations of features of the im rod ( 130 ) relative to coordinate frame a are stored in the computer &# 39 ; s long term memory . a second coordinate frame , z , is defined relative to the localizing emitters ( 137 ) of the tracking device ( 129 ) and is preferably located on the im rod ( 130 ) halfway between the transverse holes ( 131 ). it is oriented with the z - axis coincident to the long axis of the im rod ( 130 ) and the x - axis parallel to the bore of the transverse holes ( 131 ). another coordinate frame , g , is selected relative the localizing emitters ( 137 ) such that its x - axis and y - axis define a picture plane ( 138 ) upon which instrument representations may be projected to form an image for display . the z - axis of coordinate frame g is preferably oriented such that it passes through the centers of both distal transverse holes ( 131 ), thus causing representations of both distal transverse holes ( 131 ) to project to the same location on the picture plane ( 138 ). alternatively , the picture plane ( 138 ) may be selected in any pose that is near - orthogonal ( e . g ., within 20 degrees ) to the long axis of the im rod without departing from the instant invention . further , separate picture planes may be selected for each transverse hole through which the system is to assist the surgeon in inserting a screw . with the tracking device ( 129 ) attached to the im rod ( 130 ) and its pose being read by the localizing device , a graphic representation of the im rod ( 130 ) is projected onto the picture plane ( 138 ) defined by coordinate frame g . because the picture plane ( 138 ) is defined to be substantially perpendicular to the long axis of the im rod ( 130 ), the image projected on it will be an “ end - view ” of the im rod graphic representation . this end - view image is projected onto the picture plane ( 138 ) and , as shown in fig3 , is transformed into a graphic representation ( 124 ) of the im rod and displayed in a field ( 127 ) of the display screen . the software can display different versions of an instrument representation for different viewing angles . the end - view version of the im rod representation ( 124 ) is a pair of semicircles representing the cross section of the im rod ( 130 ) with a gap between them representing the transverse holes ( 131 ). virtual lines are additionally displayed as dashed lines extending from the straight portion of the semicircles to emphasize the orientation of the transverse screw holes ( 131 ). the purpose of this representation ( 124 ) is to provide the surgeon with improved information regarding the orientation and location of the transverse holes ( 131 ) in the axial plane . returning to fig1 , the c - arm ( 110 ) acquires x - ray images ( 125 and 126 ) of the bone ( 133 ) that include the transverse holes ( 131 ) of the inserted im rod ( 130 ). these images ( 125 and 126 ) need not be exactly anteroposterior or exactly lateral with respect to the im rod ( 130 ) ( i . e ., “ perfect circles ” need not be obtained ). the c - arm ( 110 ) need be oriented only to within about 30 degrees of exactly ap or lateral , and the misalignment may be either axial or oblique . the pose of the c - arm ( 110 ) and the pose of the tracking device ( 129 ) and its related coordinate frame a are calculated by the localizing device ( 120 ) when the image is acquired . if the x - axis ( 134 ) or y - axis ( 135 ) of coordinate frame a is within , preferably , 30 degrees of the source - receiver axis of the c - arm ( 110 ), then the image is considered lateral or anteroposterier ( ap ) respectively . if the acquired image is determined to be an ap view then , as shown in fig3 , the software will generate an ap version of the graphic representation ( 145 ) of the im rod which is intended to highlight the transverse holes ( 131 ). this graphic representation ( 145 ) is defined relative to coordinate frame a , and is overlaid onto the ap image ( 126 ) of the im rod ( 130 ). this ap version of the im rod representation ( 145 ) comprises lines along the sides of the transverse holes &# 39 ; image ( 141 ), with dashed virtual lines extending from either side to emphasize the orientation of the holes ( 141 ). the drill guide representation ( 123 ) is displayed relative to the im rod representation ( 145 ) as both are overlaid on the ap image ( 126 ) and improves the surgeon &# 39 ; s ability to accurately align the drill guide ( 128 ) with the im rod transverse holes ( 131 ) in the coronal plane . if the acquired image is determined to be a lateral view then the software will optionally generate a lateral version of the graphic representation ( 144 ) of the transverse holes ( 131 ). this graphic representation ( 144 ) comprises two circles representing the openings of the two holes . it is overlaid on the transverse holes ( 141 ) seen in the lateral image ( 125 ) to improve the surgeons ability to identify the starting point for the drill . however , this is of less importance when compared to the utility of the cross - sectional graphic ( 127 ). alternatively , the graphic representation ( 124 , 144 and 145 ) of the im rod ( 131 ) may take other forms including 3 - d surface models , bitmaps , or other wireframe models . any version of the graphic representations ( 124 , 144 and 145 ), regardless of view orientation , that provides the surgeon with sufficient information to orient the drill guide ( 128 ) relative to the im rod ( 130 ) in a given plane may be used without departing from the instant invention . additionally , as each image is acquired , adjustment of the position of the graphic representation ( 124 , 144 , and 145 ) of the im rod ( 130 ) is performed to correct for any deviation due to flexure of the im rod ( 131 ) or inaccuracies in attachment of the tracking device ( 129 ) or other conditions leading to inaccuracies in localizing the im rod ( 130 ). turning to fig4 , the poses of the im rod tracking device ( 129 ) and the c - arm ( 110 ) are recorded at the time of image acquisition . if the c - arm source - receiver axis ( 150 ) is within , preferably , 30 degrees of the x - axis or y - axis of coordinate frame z then adjustment is to be performed along the y - axis or x - axis , respectively . while the following adjustment steps are illustrated in fig4 , they are preferably performed without being displayed to the user . the adjustment is accomplished by projecting this adjustment axis ( 151 ) of the z coordinate frame , onto the acquired image ( 125 ) using the conic projection model , and then analyzing the image data along a specific segment ( 156 ) of this projected line ( 155 ). image processing techniques known to those skilled in the art threshold the image data within the image data segment ( 156 ) and find the center ( 158 ) of the radio - opaque im rod image ( 140 ). the difference between this image location ( 158 ) and the projected origin ( 157 ) of coordinate frame z is calculated and the difference value stored . alternatively , any image processing techniques , or other means for directly measuring the positional error of the im rod ( 130 ) at or near the transverse holes ( 131 ) may be used without departing from the instant invention . when the difference value for ap , lateral , or both images have been processed , the corresponding z frame x - axis and y - axis components are calculated by techniques known in the art . these difference components are then used to develop an adjustment transformation . returning to fig3 , this adjustment transformation is applied to coordinate frame a , causing it to rotate such that the im rod &# 39 ; s ap and lateral graphic representations ( 144 and 145 ) defined relative to a , will align with the im rod &# 39 ; s x - ray images ( 140 ). after the adjustment rotations , the positions of the cross sectional representation ( 124 ), the ap representation ( 145 ), and the optional lateral representation ( 144 ), which are displayed to the user , more accurately represent the actual position of the im rod ( 130 ). alternately , the overlay of the graphic representations ( 124 , 144 and 145 ) may be corrected by the translation of coordinate frame a instead of by rotation . or , instead , the graphic representations ( 124 , 144 and 145 ) could be altered to effect the correction . for example , if the total difference is attributed to bending of the rod , the coordinate frame a could be left unchanged and the graphic representations ( 123 , 144 and 145 ) could be altered to simulate the flexure of the im rod ( 130 ). any correction means that uses the difference between the expected and actual positions of the im rod ( 130 ) to modify its graphic representation in such a way to make it more accurate may be used without departing from the instant invention . in summary , the software steps required are shown in fig5 . the image is acquired ( 160 ) and the poses of the c - arm and tracking clamp determined ( 161 ). if the y - axis of the z coordinate frame is near - aligned with the c - arm ( 162 ) then project the z frame x - axis onto the image ( 163 ), isolate an appropriate segment of image data along the projected line ( 164 ), apply a thresholding algorithm to emphasize the im rod ( 165 ), find the center of the im rod in the image data ( 166 ), and calculate the difference between the center of the im rod &# 39 ; s image and the projected z - frame &# 39 ; s origin as modeled ( 167 ). if the x - axis of the z frame is near aligned with the c - arm ( 168 ) then project the y - axis onto the image ( 169 ) and perform the image processing steps above ( 164 - 167 ). calculate an adjustment transformation based on available x - axis and y - axis difference values ( 170 ). returning to fig1 , once the corrected im rod representations ( 124 and 144 and 145 seen best in fig3 ) are being displayed , the surgeon prepares to drill the holes in the bone ( 131 ). the drill guide ( 128 ) generates a trajectory ( 123 ) that overlays both image fields ( 125 and 126 ) and projects onto the graphics field ( 127 ) as well . as shown in fig3 , the surgeon aligns the drill trajectory ( 123 ) to pass through the hole markers of the ap im rod representation ( 145 ) and through the hole path on the cross sectional im rod representation ( 124 ) in the graphics field ( 127 ). once the proper alignment is achieved , the drill is advanced in the drill guide ( 128 ). the second hole is prepared in a similar fashion and confirmatory x - rays are obtained prior to inserting appropriately sized screws . alternately , self - tapping screws may be directly inserted with a suitable instrument . while the above description relates to the placement of interlocking screws in intramedullary rods placed in long bones , persons skilled in the art will recognize the applicability of this invention to other devices in other locations of the body such as the insertion of screws into other implantable devices . any procedure wherein a first device is positioned relative to a second device at a position that is not known with sufficient accuracy by use of a localizing device can be performed in a more accurate manner with this invention .
a computer assisted surgery system for positioning a surgical implant within a patient &# 39 ; s body that includes a localizing device configured to measure a pose of the surgical implant , an imaging device adapted for acquiring images of the surgical implant , and a computer adapted for calculating an adjusted pose for the surgical implant based on information developed from the images so as to compensate for deformation of the surgical implant or inaccuracies in localization .