LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

2D Interpolation

Solved!
Go to solution

Hi

 

I would like to see your code for this, would u like to uploade?

 

mvh

Nikolaj

0 Kudos
Message 11 of 18
(3,699 Views)

I've created the same vi and uploaded it for anybody want to do the same thing 🙂

 

 

2016-04-24_15-36-46.png

Message 12 of 18
(3,643 Views)

I add another interpolation vi...

nothing fancy... it was written and posted in thread that was deleted ...

the task was, to make a guess of a heatsource position with a given temperature sensor array

(and some hint how to solve that for more fingers/heat sources )

interpolate 2D.png

 

Greetings from Germany
Henrik

LV since v3.1

“ground” is a convenient fantasy

'˙˙˙˙uıɐƃɐ lɐıp puɐ °06 ǝuoɥd ɹnoʎ uɹnʇ ǝsɐǝld 'ʎɹɐuıƃɐɯı sı pǝlɐıp ǝʌɐɥ noʎ ɹǝqɯnu ǝɥʇ'


Message 13 of 18
(3,300 Views)

I have a problem when using this 2D Array interpolation.vi. It fails for some cases, where the missing data points are on the edges.

 

becker_r4Ak5_0-1623666945830.png

here all fine 🙂

 

becker_r4Ak5_1-1623667031769.png

 

The vi is more or less exactly the same like the one uploaded here. 

 

becker_r4Ak5_2-1623667222890.png

 

The locations of data points and missing data points fed into the Interpolate 2D scattered.vi is found correctly. That is why i`m not sure what else could be wrong. Any idea? Thanks in advance ^^ 

0 Kudos
Message 14 of 18
(2,620 Views)

Hi becker,

 


@becker_r4Ak5 wrote:

I have a problem when using this 2D Array interpolation.vi. It fails for some cases, where the missing data points are on the edges.


Where does the VI "fail"? It still produces an output so it gives no error.

I would even say it produces the expected output!

 


@becker_r4Ak5 wrote:

The vi is more or less exactly the same like the one uploaded here. 


Why don't you attach the VI?

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 15 of 18
(2,615 Views)

It should replace all the NaN pixels with interpolated ones. So in my interpolated result i don't want any NaN pixels.

0 Kudos
Message 16 of 18
(2,614 Views)

Hi becker,

 


@becker_r4Ak5 wrote:

It should replace all the NaN pixels with interpolated ones. So in my interpolated result i don't want any NaN pixels.


Using "cubic" interpolation you cannot interpolate outside of the defined area, so the interpolation function will give you NaNs as shown in your images.

 

You might switch to the "Nearest" interpolation method to remove all NaNs. (Or you implement a combination of both methods: Use "nearest" only for those elements, where "cubic" results in a NaN value…)

 

(Btw. by using conditional tunnels you could simplify this somewhat older VI.)

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 17 of 18
(2,593 Views)

Many thanks Gerd for your suggestions.

0 Kudos
Message 18 of 18
(2,571 Views)