[Rtk-users] The preprocessing for .bmp and .tif images

Guangming Zang guangming.zang at kaust.edu.sa
Tue Jun 16 14:14:02 EDT 2015


Hi Chao,
Thanks so much for your kind and very prompt reply.

Actually,  we do not have the pixel size information in image. what we know
about TIF image is :
*1916*1536 dimensions*
*300 dpi*
*16 bit depth*

And also i  have the information in the geometry .xml file about the
detector:

DetectorPixelsX=1916
DetectorPixelsY=1536
DetectorPixelSizeX=0.127
DetectorPixelSizeY=0.127

and the tif images's X and Y are the same with Detector(i.e., 1916*1536)
 so that's why i think the pixelsize IN  TIF is 0.127.
Sure  i downloaded the latest version of RTK this afternoon and have not
tried it yet. Thanks very much for this important information.

Best regards
Guangming





*Guangming Zang (Alex)*
*King Abdullah University of Science and Technology(KAUST)*
*University of Chinese Academy of Sciences(UCAS)*




2015-06-16 20:58 GMT+03:00 Chao Wu <wuchao04 at gmail.com>:

> Sorry, not "neworigin" but "newspacing"
>
> 2015-06-16 19:56 GMT+02:00 Chao Wu <wuchao04 at gmail.com>:
>
>> Then it probably means the pixel size RECORDED IN TIF is 1 mm, or the
>> pixel size is NOT SET and then by default of itk/rtk 1 mm...
>> By the way with the latest version of rtk you can overwrite the
>> projection image metadata (including pixel size) with command line
>> argument. You can try to put --neworigin 0.127 and see what happens.
>>
>> Regards,
>> Chao
>>
>>
>> 2015-06-16 19:42 GMT+02:00 Guangming Zang <guangming.zang at kaust.edu.sa>:
>>
>>> Thanks Chao and Simon.
>>> Yes, my .tif images are 16 bit depth( uint16 ) , i think it is the same
>>> with unsigned short.
>>> Another question related to  geometry is that, several months ago, i
>>> asked the tif file geometey settings, and Chao replied and kindly
>>> pointed that
>>> <http://webcache.googleusercontent.com/search?q=cache:1KHuL-ayALwJ:public.kitware.com/pipermail/rtk-users/2014-November/000621.html+&cd=1&hl=en&ct=clnk&gl=sa>
>>> i should be careful about image's dpi
>>> But, i still can not understand why it is related to image's dpi.
>>>  For example, my tif images' information and some geometry information
>>> from scanner are like this:
>>> * 1916*1536 dimensions *
>>> *  pixelsize 0.127*
>>> *  SDD  983*
>>> *  SID    413*
>>> The interesting part is that, when using  rtksimulatedgeometry  command
>>> ,  i set all parameters identical to physical distance (mm). it does
>>> not show anything, not matter care about dpi or not(suppose   rtkfdk
>>> command after that  is correct). i.e.,
>>> 1. rtksimulatedgeometry -n 360 -o geometry.xml   --sdd="983"
>>> --sid="413"    --proj_iso_x="-121.666" --proj_iso_y="-97.536"
>>>
>>> or change the sid to 2/3 *sid because of  300 dpi instead of 200 dpi
>>> 2. rtksimulatedgeometry -n 360 -o geometry.xml   --sdd="655.3333"
>>> --sid="413"    --proj_iso_x="-121.666" --proj_iso_y="-97.536"
>>>
>>>
>>> But when i set the *sdd *divide by pixelsize(0.127),  and other
>>> parameters like this, it reconstructed a  volume seems correct(at least
>>> show the whole object)
>>>
>>> 3. rtksimulatedgeometry -n 360 -o geometry.xml   --sdd="7740.15748"
>>> --sid="413.423889"    --proj_iso_x="-958" -proj_iso_y="-768"
>>>
>>> so would you please help me to find what happened??
>>>
>>> Sorry , again for this long letter. :(
>>>
>>> Thanks very much.
>>>
>>> With my Regards
>>> Guangming
>>>
>>>
>>>
>>>
>>>
>>> *Guangming Zang (Alex)*
>>> *King Abdullah University of Science and Technology(KAUST)*
>>> *University of Chinese Academy of Sciences(UCAS)*
>>>
>>>
>>>
>>>
>>> 2015-06-16 17:43 GMT+03:00 Simon Rit <simon.rit at creatis.insa-lyon.fr>:
>>>
>>>> Hi,
>>>> This is correct if your tif is of type "unsigned short".
>>>> Simon
>>>>
>>>> On Tue, Jun 16, 2015 at 4:41 PM, Chao Wu <wuchao04 at gmail.com> wrote:
>>>> > Look at http://www.openrtk.org/Doxygen/dot_inline_dotgraph_16.png
>>>> > For tif and bmp I think they go through the left most path (except
>>>> for the
>>>> > Elekta branch).
>>>> >
>>>> >
>>>> > 2015-06-16 15:47 GMT+02:00 Guangming Zang <
>>>> guangming.zang at kaust.edu.sa>:
>>>> >>
>>>> >> Hi RTK community,
>>>> >> Sorry to bother you again,  but i was wondering for the projections
>>>> in the
>>>> >> format of .bmp and .tif files. (e.g., say the bmp images  range from
>>>> >> [0,255], tif images range from [1,521]) . what are the next steps and
>>>> >> preprocessing pipelines in RTK for bmp and tif ?? I look into the
>>>> >> rtkProjectionsReader.txx, however, for me, i think it does not
>>>> explain
>>>> >> clearly.
>>>> >> So anyone can help me?
>>>> >>
>>>> >> with my Regards
>>>> >> Guangming
>>>> >>
>>>> >> Guangming Zang (Alex)
>>>> >> King Abdullah University of Science and Technology(KAUST)
>>>> >> University of Chinese Academy of Sciences(UCAS)
>>>> >>
>>>> >>
>>>> >>
>>>> >>
>>>> >> ________________________________
>>>> >> This message and its contents, including attachments are intended
>>>> solely
>>>> >> for the original recipient. If you are not the intended recipient or
>>>> have
>>>> >> received this message in error, please notify me immediately and
>>>> delete this
>>>> >> message from your computer system. Any unauthorized use or
>>>> distribution is
>>>> >> prohibited. Please consider the environment before printing this
>>>> email.
>>>> >
>>>> >
>>>>
>>>
>>>
>>> ------------------------------
>>> This message and its contents, including attachments are intended solely
>>> for the original recipient. If you are not the intended recipient or have
>>> received this message in error, please notify me immediately and delete
>>> this message from your computer system. Any unauthorized use or
>>> distribution is prohibited. Please consider the environment before printing
>>> this email.
>>>
>>
>>
>

-- 

------------------------------
This message and its contents, including attachments are intended solely 
for the original recipient. If you are not the intended recipient or have 
received this message in error, please notify me immediately and delete 
this message from your computer system. Any unauthorized use or 
distribution is prohibited. Please consider the environment before printing 
this email.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/rtk-users/attachments/20150616/49013a7f/attachment-0010.html>


More information about the Rtk-users mailing list