Closed qq609299174 closed 7 years ago
Different python version.
Change if ytarget!=None:
to if type(ytarget)!=type(None):
Hi there,
@kaz-Anova your suggestion works.
A more pythonic way would be :
if ytarget is not None:
Cheers, Olivier
Thanks! Problem solved.
Hi, I just run the file make_stacknet_data.py It shows the error as following: Traceback (most recent call last): File "D:/J/stacknet/make_stacknet_data.py", line 113, in
main()
File "D:/J/stacknet/make_stacknet_data.py", line 104, in main
dataset2()
File "D:/J/stacknet/make_stacknet_data.py", line 93, in dataset2
fromsparsetofile("dataset2_train.txt", x_train, deli1=" ", deli2=":",ytarget=y_train)
File "D:/J/stacknet/make_stacknet_data.py", line 25, in fromsparsetofile if ytarget!=None: ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()
I don't understand how it comes.