IMAQ Unflatten string image

Hello

I use the IMAQ flatten image for the vi string to flatten an acquired image and write it to the binary file. Later, when I read the binary file and try with it chain unflatten, I get an error message:

74 error to Unflatten channel into frames get & Process.vi

Possible reasons:

LabVIEW: Memory data structure or corrupted.

What I am doing wrong? I've attached screenshots to flatten and unflatten operations.

Thank you

Soheyl

I actually found the problem. For future reference: I added a flatten the IMAQ Image to a string on the diagram to unflatten and wired his output to the terminal 'data type' binary file reading. May not be a more elegant solution, but it works.

Tags: NI Software

Similar Questions

  • Unflatten string or Type Cast?

    Hello.

    I send you an array of unsigned integer 8 bit with size 19203 since a TCP server in a c for a TCP client program in LabVIEW. I managed to receive the data, as shown in the image below. The first byte, which is sent by the c program is the header. The second and the third byte represent the size of the array, which is actually 160 x 120. Then the rest of 19200 bytes are the actual values for the table.

    My client TCP code looks like this:

    This problem occurs when I am replacing the cast of Type with the Unflatten to the string function and adding a dimension to two tables. The first two values in the table (120 and 160) must inform the Unflatten to the string of the size of the array function, but I don't get all the data of the table indicator.  Is there a way to create a 160 x 120 size chart from data in 8-bit uint 2d?.

    Orlando,

    Your client with the table 1 d code gets the data, but not in the format 2D, right? If so, use Array reshape. It also can automatically adapt to any size of 2D array where the first two elements of the 1 d array contains the dimensions of the 2D table.  I put the code outside the loop just because there was space on the comic it. It can be moved inside if you receive multiple messages.

    Lynn

  • System error IMAQ using IMAQ Clipboard to Image

    Hello

    I have a VI that prints screen then use the Cliboard IMAQ to Image function to get the image into something that I can handle in LabVIEW.

    It works perfectly when I'm in the LabVIEW environment. As soon as I select any other program LabVIEW throws the below error. I don't know if it is a mistake to LabVIEW or something to do with how the window Clipboard works.

    Any help would be appreciated, or any other ideas of how to take a picture of what is on my computer for analysis in LabVIEW.

    VI attached below - LV 2015

    Hello

    I can get the .VI for work in any active window if I change the I8 second from the node of function call library from 0 to 1.

    I hope this helps.

    Kind regards

    Nathan

  • IMAQ fully black image output local threshold

    Hi all, I have written a script easy to read in a set of images, do some processing on their basis of the image and view the results. My problem occurs when I try to use the local threshold IMAQ in my script block - the program runs and displays the images very well without it. But once I got through the local threshold IMAQ block in the image, it only shows a completely black image.

    I know this should not be the case because I literally copied and pasted the same blocks generated by the wizard of Vision in my code, and I confirmed that runs the same image through the same series of blocks generates in a simple script seuillee that is not completely black image.

    Someone has an idea what could be the cause? Could it have to do with my version of Labview in 2011 and my version of labview for 2013 vision? I'm a newbie to labview so I feel that I must be missing something obvious...

    While I am, my ultimate goal is to be able to follow a whale in a video. Does anyone have suggestions about where to start on this very heavy problem? I started looking into the estimation of movement and followed subject screws, of course, any advice on how to implement a robust solution would be welcome. I want to use a bunch of case statements to change how I'm Imaging before doing an analysis of movement?

    Thanks in advance for the help! I have attached my script below.

    Hello

    regarding the first part (threshold), try right-clicking on the image, then select binary palette. Your other option is to use imaq multiply by a constant (value max 255, 8-bit image).

    Validation of my cell phone, so I can't check the fixing up tomorrow...

    I hope this helps a little.

    Best regards
    K

  • Unflatten string Variant received the error 122

    Hello

    In this VI, when I used a 13-character string to write data flattened in a file, I got error 122 when new reading and unflattening. But with string which was not 13 characters, the unflattening operation has worked very well.

    Any ideas?

    Make sure that you disable the EOL 'convert '.  That could change your data on you flattened.  Alternatively, you could read and write with the help of a binary file.

  • Error 74 to unflatten string in a device helping custom interface hardware Inline

    Hello

    I am creating a custom device Interface material Inline to communicate on a bus series to Veristand. I want only to communicate via RS232 veristand channel values, I use flatten/unflatten to chain to transfer my data. I choose what it because VISA Write/Read uses strings, and he would always use the same size of string (channels Veristand = 64-bit double-online 8 character string).

    But when it comes to try it with veristand, I have error 74: corrupt memory or data structure. I noticed this error came from the "string unflatten".

    So I plugged in a "clear error" vi just after "unflatten to channel" works, for my custom device runs but gives me wrong results. Then I used the tool NI OF Trace to see what I was writing to the RS232 bus. You can find the result of this. When we take a glance on the viWriteasync functions, we can see that the data written on the bus will already '?... " W.... M' which translates as 0,000232195, although the value that I have passed to the bus was greater than 1.

    I plugged the constant 'false' by 'add array or string of size' 'flatten in string' and 'unflattend to the string' functions.

    Does anyone have an idea what's wrong?

    Kind regards

    Maxim

    Is your session series Visa implemented to put an end to strings with the null character? It's been a while since I worked with serial number, but I remember this could be the case. So then you'd have trouble sending binary data flattened since it would have a lot of characters in it null. Another solution would be to format doubles as text with a specified number of digits of precision, although this will be less accurate and can take more bytes to transfer.

  • IMAQ resample invalid image type

    Hello

    I'm rewriting an old non-versatile version of a VI. I don't have much experience but I have the old VI as a kind of model for what I do. It's weird, but even if I try to do things exactly the same way, they do not work.

    I acquire an image high resolution camera (IMAQ to acquire) which is too large (1280 x 1024). I want to resample (IMAQ resample) at 256x320px.

    I get the error message: error-1074396080 occurred in the type of IMAQ image resample not valid.

    The probe I put to read of the Src of the Image shows the image correctly and tells me that it is a 16-bit unsigned image. This should be a valid image type, right?

    Dennis

    Deneck wrote:

    I get the error message: error-1074396080 occurred in the type of IMAQ image resample not valid.

    The probe I put to read of the Src of the Image shows the image correctly and tells me that it is a 16-bit unsigned image. This should be a valid image type, right?

    No, not right. IMAQ resample does not support the type of U16 (at least until VDM2011). See help.

    Convert your image to I16 (if possible) before resampling.

    Andrey.

  • Train of SVM IMAQ for no Image data

    Hello

    I am fairly new to machine algorithms for learning about Labview so please be patient if my question seems stupid. I was wondering if there is a workaround to use the screw of Machine Vision SVM (e.g. IMAQ SVM Train) for not the image data. I know Machine learning package and I will surely give it a try with those but MV screws are really well organized and allow to record the training in a very elegant manner.

    Indications, suggestions or, well, even a "no, can't it' is really appreciated!

    Moreover, any luck of having the learning algorithm Machine present natively in LV?

    Thank you

    FRAX

    -According to my knowledge IMAQ screws are specifically for the Images.

    -Your best chance is using Machine learning package that you have already found.

  • Can Unflatten string could be used to play the waveform given .dat file

    Hi, refer to these two threads

    http://forums.NI.com/T5/LabVIEW/can-LabVIEW-read-dat-file/TD-p/2243080

    http://forums.NI.com/T5/LabVIEW/2-complement-hex-convert/TD-p/2245980

    I tried to read the file Dat using string Unflatten and Got this error.

    Can someone tell me how to do?


  • IMAQ: 'not an image' errors using the IMAQdx snap

    Hello world

    I have a strange error that I do not understand. The part of the VI is fixed.

    Basically, I take some pictures (10 to 20 years) of a region of interest and their average in one, I want to save and post processing. In particular, I want to get the value of each pixel gray scale.

    The problem is that the result is not 'a picture '. I can view, but not to save it to disk, or perform a filtering or even (like the edge detection). I add a 'cast image' module to try to force it, but it is not good.

    I am quite new to Labview, so I assume that the error is obvious, but I can't find it! I compared my VI with existing, without success.

    In addition, my method to establish the average return on investment can be improved, do not hesitate to propose more efficient designs.

    Thanks in advance for your help,


  • IMAQ Vision: The image is not big enough for the operation (Imaq WriteToPNG.vi)

    Hi all

    I was stuck for a few days trying to get my work VI and get this error. It is as simple as to save a graph of intensity as an IMG, he works with JPEG formats but my graph is U16 grayscale and it is not supported by the jpeg format so I didn't get the expected results. Then I went to the PNG format and the error "the image is not big enough for that operation" appeared. I tried to resize as aid error NOR suggest, and got the same error, anyone has an idea on what could be the problem?

    Hello Bob,

    Thanks for the tips, I'll post my code in future issues (since I already solved this one). As you say, there was something wrong with my code, the code in the image actually worked well, but doesn't have the part where I wrote to the variable (the variable was not being written if its value is an array of 0x0, not big enough actually). Thank you!

  • Hi, can someone give me some ideas on what type/brand of usb cameras are not suitable for labview? I need to use with labview and IMAQ Cheers acquisition image vision module

    Hi, can someone give me some ideas on what type/brand of usb cameras are not suitable for labview? I need to use with labview and image acquisition IMAQCheers vision module

    Hi, I use a 1.4MP USB camera with LabView. The brand is ID - a German company.

  • the string image

    I add a shadow to my image. My topic is several feet from the wall, so the angle of shadow cast will change abruptly where the floor meets the wall. How can I warp this shadow to the desired angle effect? So far, all I see with the warp tool is a curved effect - no way to bend an image on a flat surface. In short, I need this image to bend sharply upward, not the curve, where the floor meets the wall.

    First, Bill, your layers must be configured in this way:

    Was: should understand that green background.

    B. is created when you apply a drop shadow C and then apply the following:

    In CS4, it reads create layers instead of creating layer, but it is there. Guaranteed.

    C. the top layer is your silhouette

    After your first tilt to tilt and drag the shadow, OK it. So make this choice of shadow (not a shadow of all) and the vertical left tilt.

    Notice that the selection extends along the horizon line. As you can see in the case of this image, the person is not very far from the 'wall' if the articulation of the shadow will be not significant. If you want a more dramatic shadow joint, it must be placed further away from the wall and one more steep first slope.

  • LV 2012 Flatten To String / string problems Unflatten

    I use a simple flatten to a string in order to save a setup of controls, then a unflatten string read saved orders.  The problem is when I try to read the file, it returns an error message:

    122 error to Unflatten string in front Panel.vi Installer

    Possible reasons:

    LabVIEW: The resource you are trying to open was created in a newer version of LabVIEW and is not compatible with this version.

    Which is wrong, because it was created in the same VI about 8 seconds earlier.  Are there known issues with this, or any places that I might want to watch?

    Edit: This code correct, unchanged compared to now was working last night without problem.  In fact, the saved files, I have tested with last night are still working fine, but do not load recently saved files.


  • Save image 12 bit < with > imaq

    Following a previous question, I've done here, I discovered that I am able to install and use IMAQ.

    So I try to do what I need, is to record a 12-bit grayscale with IMAQ image.

    I read somewhere here that more can I go to save as 16 bit - I hope that it will not create problems in the final image.

    in any case, is to know how far I could go - trying to understand works IMAQ:

    (Sorry for the confusion - the lower left part deals with it without imaq, the party is on the right)

    It works, I get a "error-1074396154 occurred at WritePNGFile IMAQ - or the possible reasons: IMAQ Vision: the image is not big enough for that operation.

    -but just for this reason that I have inserted a SetImageSize IMAQ!

    any clue?

    Thanks for any help...

    Alessandro

    I have not installed imaq/SAV/vdm, so I'm going from memory here, but

    (1) you will encounter many problems with memory. you create a new image for each iteration of the loop and never remove. At the very least put an image destroy after imaq functions. The way I have always done things is to create the image once and then just re-use before destroying once at the end.

    (2) I think that your problem is perhaps the fact that you need to explicitly set the type of image in grayscale 16 on the imaq create functions, but I'm not positive

    This article refers

    http://digital.NI.com/public.nsf/allkb/B51CCE62D00112B68625735C0000DDCF

    These

    http://www.NI.com/example/28120/en/

    examples that may help you more

Maybe you are looking for