public static string Serialize(ManagedNN network) { var model = Convert(network); var output = JsonConvert.SerializeObject(model); return(output); }
public static ManagedNNJSON Convert(ManagedNN network) { var model = new ManagedNNJSON() { Wji = Convert2D(network.Wji), Wkj = Convert2D(network.Wkj) }; return(model); }
public static ManagedNN DeserializeNN(string json) { var model = JsonConvert.DeserializeObject <ManagedNNJSON>(json); var network = new ManagedNN { Wji = Set(model.Wji), Wkj = Set(model.Wkj) }; return(network); }