I have applied harris corner detection on saggital CT and MR images of lumbar spine. You can see the attached file for detected corners marked in red. Now i want to match them so that i can align CT with MR.
I'm not sure what these red dots represent, but if you assume that the spine is in the same position between the CT and MRI scans (this highly depends on the setup used to acquire them, but they look similar on the 2D slices you've shown) then you could try a rigid registration between these images and see how it works out.
It also looks like you're using MATLAB, if so, you could have a look at the "imregister" command which will output a translated image for you, and allow you to view both images. Theres also many other softwares that can do automated registration for you.
You could also try a simple point-matching registration as the anatomy is fairly reproducible (i.e. click on one point in the MR image, and the corresponding anatomical point in the CT).
"Rigid" registration of one of the 2D images to the other can be performed by assigning an identity to each identified point, and then calculating the necessary translation to align the two images. However, this approach does not take into account the different perspective of the scanners, different scale of the image, or movement of the patient between scans. For example, it can be seen that in the CT image L1 is not fully visible, where as in the MRI image L1 is fully visible along with most of T12.
Thus what is required is to perform 2-D transformation of one image such that the selected features in the two images match. In the basic form, this can be accomplished by calculating a 2-d transformation that is a combination of scaling, rotation, and translation (similarity transformation), or scaling, rotation, shear, and translation (affine transformation)
An example can be seen here: https://www.mathworks.com/help/images/examples/find-image-rotation-and-scale-using-automated-feature-matching.html.
Note that this still doesn't account for any nonlinearity, for example what might be expected due to the patient moving.