/
onnx_test_sinh_example.go
50 lines (39 loc) · 1.37 KB
/
onnx_test_sinh_example.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
package onnxtest
// this file is auto-generated... DO NOT EDIT
import (
"github.com/owulveryck/onnx-go/backend/testbackend"
"gorgonia.org/tensor"
)
func init() {
testbackend.Register("Sinh", "TestSinhExample", NewTestSinhExample)
}
// NewTestSinhExample version: 3.
func NewTestSinhExample() *testbackend.TestCase {
return &testbackend.TestCase{
OpType: "Sinh",
Title: "TestSinhExample",
ModelB: []byte{0x8, 0x3, 0x12, 0xc, 0x62, 0x61, 0x63, 0x6b, 0x65, 0x6e, 0x64, 0x2d, 0x74, 0x65, 0x73, 0x74, 0x3a, 0x43, 0xa, 0xc, 0xa, 0x1, 0x78, 0x12, 0x1, 0x79, 0x22, 0x4, 0x53, 0x69, 0x6e, 0x68, 0x12, 0x11, 0x74, 0x65, 0x73, 0x74, 0x5f, 0x73, 0x69, 0x6e, 0x68, 0x5f, 0x65, 0x78, 0x61, 0x6d, 0x70, 0x6c, 0x65, 0x5a, 0xf, 0xa, 0x1, 0x78, 0x12, 0xa, 0xa, 0x8, 0x8, 0x1, 0x12, 0x4, 0xa, 0x2, 0x8, 0x3, 0x62, 0xf, 0xa, 0x1, 0x79, 0x12, 0xa, 0xa, 0x8, 0x8, 0x1, 0x12, 0x4, 0xa, 0x2, 0x8, 0x3, 0x42, 0x2, 0x10, 0x9},
/*
&ir.NodeProto{
Input: []string{"x"},
Output: []string{"y"},
Name: "",
OpType: "Sinh",
Attributes: ([]*ir.AttributeProto) <nil>
,
},
*/
Input: []tensor.Tensor{
tensor.New(
tensor.WithShape(3),
tensor.WithBacking([]float32{-1, 0, 1}),
),
},
ExpectedOutput: []tensor.Tensor{
tensor.New(
tensor.WithShape(3),
tensor.WithBacking([]float32{-1.1752012, 0, 1.1752012}),
),
},
}
}