LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Renaming files based on sequence

I have a set of 3 images for an MxN pixels of certain scan.

 

  1. I have developed a code that does some image processing and renames the files as pulse-1, pulse-2 and background-1. This is for 1 pixel. Right now I can do this to only the three images that relates to One pixel that I used for testing.
  2. In futures I will be having MxN images, which means MxN pixels and I have MxNx3 images, how can I sequentially rename the files based on which pixel it corresponds to ? for ex: Pixel-1_Pulse1, Pixel-1_Pulse2 and Pixel-1_Background.

The developed code for 3 images is attached.

Abhilash S Nair

Research Assistant @ Photonic Devices and Systems lab

[ LabView professional Development System - Version 11.0 - 32-bit ]

LabView Gear:
1. NI PXI-7951R & NI 5761
2. The Imaging Source USB 3.0 monochrome camera with trigger : DMK 23UM021

OPERATING SYSTEM - [ MS windows 7 Home Premium 64-bit SP-1 ]
CPU - [Intel Core i7-2600 CPU @ 3.40Ghz ]
MEMORY - [ 16.0 GB RAM ]
GPU - [ NVIDIA GeForce GT 530 ]
0 Kudos
Message 1 of 4
(2,631 Views)

Well, the tools are "strip path", "build path", and "get file extension". The rest are simple string operations on the filename.

 

Sorry, it is not clear what exactly you are trying to do. Is each pixel a seperate image file? You seem to list all BMPs in a folder, but then only look at three files.

 

Can you show an example file list and what kind of output you expect from it?

 

 

(In the meantime, you really should do a few more tutorials. learn about autoindexing (first loop). Also don't convert the path to a string only to convert it back to what it was a few nanoseconds later. The "array to cluster...unbundle dance" is just silly. Simply use index array resized to three output. See attached).)

0 Kudos
Message 2 of 4
(2,619 Views)

"Pixel-1_Pulse1, Pixel-1_Pulse2 and Pixel-1_Background"

Sure, Format into string with pixel coords and a Enum e.g. would create the filename. Then it's a simple Build path.

/Y

G# - Award winning reference based OOP for LV, for free! - Qestit VIPM GitHub

Qestit Systems
Certified-LabVIEW-Developer
0 Kudos
Message 3 of 4
(2,611 Views)

@abikutn wrote:

I have a set of 3 images for an MxN pixels of certain scan.

 

  1. I have developed a code that does some image processing and renames the files as pulse-1, pulse-2 and background-1. This is for 1 pixel. Right now I can do this to only the three images that relates to One pixel that I used for testing.
  2. In futures I will be having MxN images, which means MxN pixels and I have MxNx3 images, how can I sequentially rename the files based on which pixel it corresponds to ? for ex: Pixel-1_Pulse1, Pixel-1_Pulse2 and Pixel-1_Background.

The developed code for 3 images is attached.


look here.....

0 Kudos
Message 4 of 4
(2,602 Views)