add framework.dygraph_only back

pull/2925/head
zxcd 3 years ago
parent 756dfb3c13
commit 30b36ed511

@ -12,6 +12,7 @@
# See the License for the specific language governing permissions and # See the License for the specific language governing permissions and
# limitations under the License. # limitations under the License.
import paddle import paddle
from paddle.fluid import framework
from paddle.optimizer import Optimizer from paddle.optimizer import Optimizer
__all__ = [] __all__ = []
@ -110,6 +111,7 @@ class SimpleAdadelta(Optimizer):
self.acc_deltas = [] self.acc_deltas = []
@paddle.no_grad() @paddle.no_grad()
@framework.dygraph_only
def step(self): def step(self):
"""Performs a single optimization step. """Performs a single optimization step.

Loading…
Cancel
Save