function inTrainPhase(x, alt, training) {
	  if (training === void 0) {
	    training = false;
	  }

	  return training ? x() : alt();
	}
Invoke `x` in the training phase, and `alt` otherwise.

Porting Note: We do not create placeholder tensors for the `training`
boolean flag here, because there is no such thing in the TF.js imperative
backend.

@param x The function to invoke iff `training` is `true`.
@param alt The function to invoke iff `training` is `false`.
@param training Boolean flag for whether training phase is active.
@returns The return value of `x()` if `training` is `true`, or the return
  value of `alt()` if `training` is `false`.