Skip to content

Conversation

abhilash1910
Copy link

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
Copy link
Author

Changes:

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

@chetaspahuja
Copy link

:shipit:

@ghost
Copy link

ghost commented Jul 18, 2024

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 , for tensorflow 2.16.x, python throws an error message when modeling.BertModel() gets called.

AttributeError: Tensor.name is undefined when eager execution is enabled.

Essentially, the issue is with name = tensor.name on line 911 in modeling.py.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants