Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix unitest #4920

Closed
wants to merge 2 commits into from
Closed

Fix unitest #4920

wants to merge 2 commits into from

Conversation

talkingwallace
Copy link
Contributor

No description provided.

Signed-off-by: cwj <talkingwallace@sohu.com>
Signed-off-by: cwj <talkingwallace@sohu.com>
@@ -96,7 +96,7 @@ def test_compute_hess(self):
pred = np.asarray([random.random() for j in range(5)], dtype='float64')
label = random.randint(0, 4)
softmaxloss_hess = self.softmax_loss.compute_hess(label, pred)
hess = pred * (1 - pred)
hess = 2 *pred * (1 - pred)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[autopep8] reported by reviewdog 🐶

Suggested change
hess = 2 *pred * (1 - pred)
hess = 2 * pred * (1 - pred)

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

Successfully merging this pull request may close these issues.

1 participant