Skip to content

Commit 5b24223

Browse files
committed
Enable resource_var when XLA is on for run_squad.py.
1 parent 65211bd commit 5b24223

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

TensorFlow/LanguageModeling/BERT/run_squad.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -965,6 +965,7 @@ def main(_):
965965
training_hooks.append(hvd.BroadcastGlobalVariablesHook(0))
966966
if FLAGS.use_xla:
967967
config.graph_options.optimizer_options.global_jit_level = tf.compat.v1.OptimizerOptions.ON_1
968+
tf.enable_resource_variables()
968969
run_config = tf.estimator.RunConfig(
969970
model_dir=FLAGS.output_dir if master_process else None,
970971
session_config=config,

0 commit comments

Comments
 (0)