k_learning_phase: Returns the learning phase flag.

View source: R/backend.R

k_learning_phaseR Documentation

Returns the learning phase flag.

Description

The learning phase flag is a bool tensor (0 = test, 1 = train) to be passed as input to any Keras function that uses a different behavior at train time and test time.

Usage

k_learning_phase()

Value

Learning phase (scalar integer tensor or R integer).

Keras Backend

This function is part of a set of Keras backend functions that enable lower level access to the core operations of the backend tensor engine (e.g. TensorFlow, CNTK, Theano, etc.).

You can see a list of all available backend functions here: https://tensorflow.rstudio.com/reference/keras/index.html#backend.


keras documentation built on Aug. 16, 2023, 1:07 a.m.