VariablesInitializer - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


DeepLearning

  

VariablesInitializer

  

initialize variables

 

Calling Sequence

Description

Details

Examples

Compatibility

Calling Sequence

VariablesInitializer()

Description

• 

VariablesInitializer() returns an Operation which can be run in a Session to initialize all the variables in the graph.

• 

Note that this command requires that eager execution be turned off beforehand using the SetEagerExecution command.

• 

This function is part of the DeepLearning package, so it can be used in the short form VariablesInitializer(..) only after executing the command with(DeepLearning). However, it can always be accessed through the long form of the command by using DeepLearning[VariablesInitializer](..).

Details

• 

The implementation of VariablesInitializer uses the tf.global_variables_initializer command from the TensorFlow Python API. Consult the TensorFlow Python API documentation for tf.global_variables_initializer for more information on random number generation during TensorFlow computations.

Examples

withDeepLearning:

SetEagerExecutionfalse

true

(1)

vVariable0.3,datatype=float8

vDeepLearning VariableName: Variable:0Shape: [1]Data Type: float[8]

(2)

initVariablesInitializer

initDeepLearning Operationname: "init" op: "NoOp" input: "^Variable/Assign"

(3)

sessGetDefaultSession

sessDeepLearning Session<tensorflow.python.client.session.InteractiveSession object at 0x7fe898c52e10>

(4)

sess:-Runinit

Python:−None

(5)

Compatibility

• 

The DeepLearning[VariablesInitializer] command was introduced in Maple 2018.

• 

For more information on Maple 2018 changes, see Updates in Maple 2018.

• 

The DeepLearning[VariablesInitializer] command was updated in Maple 2021.

• 

The  option was updated in Maple 2021.

See Also

DeepLearning Overview