Skip to content
Snippets Groups Projects
Commit 6da3bdb4 authored by Jean-Baptiste Keck's avatar Jean-Baptiste Keck
Browse files

add support for the sign function

parent b09765e4
No related branches found
No related tags found
1 merge request!16MPI operators
......@@ -120,8 +120,6 @@ def _map_func(csc, expr, promoted_args, ctype, reqs):
else:
msg='min({})'.format(ctype)
raise NotImplementedError(msg)
elif expr.func is sm.exp:
return BuiltinFunction('exp')
elif expr.func in _func_mappings:
return _func_mappings[expr.func]
return expr.func
......@@ -175,6 +173,7 @@ _func_mappings = {
sm.tanh: BuiltinFunction('tanh'),
sm.exp: BuiltinFunction('exp'),
sm.log: BuiltinFunction('log'),
sm.sign: BuiltinFunction('sign'),
sm.StrictGreaterThan: OpenClLogicalGT,
sm.StrictLessThan: OpenClLogicalLT,
sm.GreaterThan: OpenClLogicalGE,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment