Message Boards Message Boards

0
|
3451 Views
|
6 Replies
|
3 Total Likes
View groups...
Share
Share this post:

How to import an image sequence

Posted 11 years ago
Hello, 

Just a simple question: How can I import a sequence of images, lets say a DICOM sequence that I have in a folder. I tried differend options in Import command but it did not work.

Thanks.
POSTED BY: Soroush HP
6 Replies
If it is numerical or alphabetical order - it will just happen automatically:
The list of files returned by FileNames is sorted in the order generated by the function Sort.  ~ Documentation
But you can do any sort of string-processing to sort out filenames list any any way you want. 
POSTED BY: Vitaliy Kaurov
Posted 11 years ago
You are right! Thanks
POSTED BY: Soroush HP
Posted 11 years ago
Thank you very much Vitaliy,
Since I want to use the image swquence for feature tracking, is there any way I can import them in an order, for example by their names: 001, 002, 003 ,...?
POSTED BY: Soroush HP
SetDirectory["/Library/Application Support/Apple/iChat Icons/Planets"];
names = FileNames[]
Output:
{"Earth (Americas).gif", "Earth and Moon.gif", "Earth (Australasia).gif", "Earth (Clouds).gif", "Extrasolar Giant.gif", "Jupiter.gif", "Mars.gif", "Mercury.gif", "Neptune.gif", "Pluto and Charon.gif", "Saturn.gif", "Uranus.gif", "Venus.gif"}
Now just use import:
Import /@ names

POSTED BY: Vitaliy Kaurov
Posted 11 years ago
No, nothing special. Lets say it is a folder with JPEG images named as IMG_001, IMG_002, ...
POSTED BY: Soroush HP
Is there anything special about DICOM sequence or we can just assume we have a folder of images with let's say .jpg files?
POSTED BY: Vitaliy Kaurov
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract