Skip to content

Commit cde7db8

Browse files
committed
fix bad code in python
1 parent 04b8d3d commit cde7db8

File tree

2 files changed

+0
-7
lines changed

2 files changed

+0
-7
lines changed

python/paddle/fluid/layers/metric.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -64,10 +64,6 @@ def auc(input, label, curve='ROC', num_thresholds=200):
6464
topk_indices = helper.create_tmp_variable(dtype="int64")
6565
topk_out, topk_indices = nn.topk(input, k=k)
6666
auc_out = helper.create_tmp_variable(dtype="float32")
67-
if correct is None:
68-
correct = helper.create_tmp_variable(dtype="int64")
69-
if total is None:
70-
total = helper.create_tmp_variable(dtype="int64")
7167
helper.append_op(
7268
type="accuracy",
7369
inputs={

python/paddle/fluid/tests/unittests/test_dynrnn_gradient_check.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,6 @@ def update(self, val):
3030
assert val.dtype == self.ex.dtype
3131
self.cur = val
3232

33-
def ex(self):
34-
return self.ex
35-
3633
def next(self):
3734
self.ex = self.cur
3835
self.cur = None

0 commit comments

Comments
 (0)