File tree Expand file tree Collapse file tree 2 files changed +12
-1
lines changed
core/conversion/converters/impl
tests/core/conversion/converters Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -40,6 +40,10 @@ convert(ceil, kCEIL);
40
40
convert (sqrt, kSQRT );
41
41
convert (exp, kEXP );
42
42
convert (neg, kNEG );
43
+ convert (erf, kERF );
44
+ convert (asinh, kASINH );
45
+ convert (acosh, kACOSH );
46
+ convert (atanh, kATANH );
43
47
44
48
#undef convert
45
49
Original file line number Diff line number Diff line change @@ -21,7 +21,10 @@ std::string gen_test_graph(const std::string& unary) {
21
21
auto g = std::make_shared<torch::jit::Graph>(); \
22
22
torch::jit::parseIR (graph, &*g); \
23
23
\
24
- auto in = at::empty ({10 }, {at::kCUDA }).uniform_ (0 , 0.5 ); \
24
+ float offset = 0 ; \
25
+ if (strcmp (#name, " Acosh" ) == 0 ) \
26
+ offset += 1 ; /* input larger than 1 for acosh*/ \
27
+ auto in = at::empty ({10 }, {at::kCUDA }).uniform_ (0 + offset, 0.5 + offset); \
25
28
auto params = trtorch::core::conversion::get_named_params (g->inputs (), {}); \
26
29
auto jit_results = trtorch::tests::util::RunGraph (g, params, {in}); \
27
30
\
@@ -48,5 +51,9 @@ test_unary(ceil, Ceil);
48
51
test_unary (sqrt, Sqrt);
49
52
test_unary (exp, Exp);
50
53
test_unary (neg, Neg);
54
+ test_unary (erf, Erf);
55
+ test_unary (asinh, Asinh);
56
+ test_unary (acosh, Acosh);
57
+ test_unary (atanh, Atanh);
51
58
52
59
#undef test_unary
You can’t perform that action at this time.
0 commit comments