I'm trying to train a network to take 3 integers and give an output = Max/Min. For example {10, 20, 30} -> 3. But I cannot get the setup correctly. I must be missing something.
x = Table[{RandomInteger[{1, 100}], RandomInteger[{1, 100}],
RandomInteger[{1, 100}]}, 1000];
y = (Max[#]/Min[#] // N) & /@ x;
t = x -> y // Thread;
net = NetChain[{LongShortTermMemoryLayer[10],
LongShortTermMemoryLayer[10], LinearLayer[1]}, "Input" -> {3, 1},
"Output" -> 1]
p = NetTrain[net, t, ValidationSet -> Scaled[0.1]]
I get the following error:
NetTrain: Data provided to port "Input" should be a non-empty list of 3x1 matrices of real numbers, but was a 1000x3 matrix of real numbers.