bert icon indicating copy to clipboard operation
bert copied to clipboard

PR to resolve issue #1140 - AttributeError: module 'tensorflow._api.v2.train' has no attribute 'Optimizer'

Open abhilash1910 opened this issue 5 years ago • 3 comments

This PR has a minor modification to remove the error due to tensorflow version (>=2) incompatibility for optimizer.py. Due to deprecation of 'tf.train.Optimizer', an improvement is made which allows the optimizer to run smoothly with tf version>=2(tested locally with 2.3.1) . Suggestions are appreciated.Thanks

abhilash1910 avatar Oct 01 '20 07:10 abhilash1910

Changes:

  1. Provided python 2 support for _run_split_on_punc (tokenization.py)
  2. Provided tf2 options in modeling.py and modeling_test.py

abhilash1910 avatar Apr 24 '21 13:04 abhilash1910

:shipit:

chetaspahuja avatar Aug 24 '21 18:08 chetaspahuja