/// <summary> /// Marks this tensor to be watched by the given tape. /// </summary> /// <param name="x"></param> public void Watch(long tensor_id) { if (!CouldBackprop()) { return; } tensor_tape_.emplace(tensor_id, -1); }
/// <summary> /// Marks this tensor to be watched by the given tape. /// </summary> /// <param name="x"></param> public void Watch(long tensor_id) { if (!CouldBackprop()) { return; } tf.Logger.Debug($"Watch tensor_id={tensor_id}"); tensor_tape_.emplace(tensor_id, -1); }
/// <summary> /// Marks this tensor to be watched by the given tape. /// </summary> /// <param name="x"></param> public void Watch(Tensor x) { tf.Logger.Debug($"Watch tensor id={x.Id}, name={x.name}"); tensor_tape_.emplace(x, -1); }