Wolfram Language

Train a Neural Network on a Remote System

RemoteConnect can be used to create a connection to a remote machine, and programmatically interact with it. In this case it is used to launch a script, training a neural network on a more capable computer.

Connect to a remote machine.

Create a Wolfram Language script on the remote machine to perform neural network training.

#!wolframscript data=Flatten@Table[{x,y}->Exp[-Norm[{x,y}]],{x,-3,3,.01},{y,-3,3,.01}]; net=NetChain[{32,Tanh,1}]; trained=NetTrain[net,data,BatchSize->1024, TimeGoal->10,TrainingProgressReporting->"Print"] Export[$HomeDirectory<>"/trained.wlnet", trained, "WLNet"]

Use WriteLine to send commands to the remote machine without waiting for them to return.

When the evaluation completes, use ReadString to read the results.

Close the connection.

Related Examples

de fr ja pt-br zh