public virtual void ReceiveData(Message rx) { if (CurrentlyTraining) { InputMessages.Add(rx); bool contains = false; foreach (LeakyIntegrateAndFireNode n in InputMesssageNodes) { if (n == rx.Synapse.Source) { contains = true; break; } } if (!contains) { InputMesssageNodes.Add(rx.Synapse.Source); } } }
public virtual void Apply(Context context) { //Copy some specific data InputMessages.AddRange(context.InputMessages); OutputMessages.AddRange(context.OutputMessages); }