79239313

Date: 2024-11-30 10:26:12
Score: 2
Natty:
Report link

import numpy as np

def softmax(x): """ Softmax函数实现 """ e_x = np.exp(x - np.max(x)) return e_x / e_x.sum()

假设的带符号8个整数输入

input_numbers = np.array([-2, 1, 3, -1, 0, 2, 4, -3])

softmax_result = softmax(input_numbers)

print(softmax_result)

Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: shaw