Classification-of-Hyperspectral-Image
Classification-of-Hyperspectral-Image copied to clipboard
"NameError: name 'numComponents' is not defined",
hello, I tried the code, the frist two-CreatetheDatasets and TrainTheModel all run successfully, but when I run the last code-validation, the sentence "file_name = 'report'+"WindowSize" + str(windowSize) + "PCA" + str(numComponents) + "testRatio" + str(testRatio) +".txt"" represent the question, said "NameError: name 'numComponents' is not defined", This mean it can't find the corresponding file and data, which means I didn't save some training results? I don't know how to slove, can you help me? thanks a lot