03-12-2022 03:36 AM
Hello everyone,
I'm trying to run python node in LabView, but script return error 1672.
With script everything ok, but LabView have some problems.
Solved! Go to Solution.
03-14-2022 01:51 AM
Hello, NoKot333. Do you use any Numpy functions?
03-14-2022 02:53 AM
What is your LabVIEW version?
03-14-2022 05:02 AM
I found the possible solution for this error.
https://knowledge.ni.com/KnowledgeArticleDetails?id=kA03q000000YHqWCAW&l=en-US
03-14-2022 07:17 AM - edited 03-14-2022 07:22 AM
@Vazgen_H wrote:
Hello, NoKot333. Do you use any Numpy functions?
I can confirm, I have seen error 1672 when returning a numpy array which is generated by the python script
in the following, I write a 2d buffer to the python node, extract the first column of this 2d buffer, convert this column vector to a numpy array and return as 1d array of doubles "y".
import numpy as np
def return_cm(data):
y = data[:, 0]
X = data[:, 1:]
y = np.array(y)
return y
the length of the y-vector can be manipulated by choosing a different number of rows, in the following screenshot 1000:
Error 1672 does halt the .vi, when the numbers of rows in this vector is bigger ~ 10.000 , but will work corretly if less e.g. 1000
03-15-2022 01:45 AM
There are some Numpy functions, which are not supported by LabVIEW.
03-15-2022 07:33 AM
Hello again. Can you send me kwhFinal.h5 for testing code on my PC?
03-17-2022 02:38 AM
Yes
03-17-2022 02:38 AM
21.0.1 (64-bit)
03-17-2022 02:41 AM