@@ -519,24 +519,22 @@ def numba_funcify_CAReduce(op, node, **kwargs):
519519
520520 scalar_op_identity = np .asarray (op .scalar_op .identity , dtype = np_acc_dtype )
521521
522- acc_dtype = numba .np .numpy_support .from_dtype (np_acc_dtype )
523-
524522 scalar_nfunc_spec = op .scalar_op .nfunc_spec
525523
526524 # We construct a dummy `Apply` that has the minimum required number of
527525 # inputs for the scalar `Op`. Without this, we would get a scalar function
528526 # with too few arguments.
529527 dummy_node = Apply (
530528 op ,
531- [tensor (acc_dtype , [False ]) for i in range (scalar_nfunc_spec [1 ])],
532- [tensor (acc_dtype , [False ]) for o in range (scalar_nfunc_spec [2 ])],
529+ [tensor (np_acc_dtype , [False ]) for i in range (scalar_nfunc_spec [1 ])],
530+ [tensor (np_acc_dtype , [False ]) for o in range (scalar_nfunc_spec [2 ])],
533531 )
534532 elemwise_fn = numba_funcify_Elemwise (op , dummy_node , use_signature = True , ** kwargs )
535533
536534 input_name = get_name_for_object (node .inputs [0 ])
537535 ndim = node .inputs [0 ].ndim
538536 careduce_fn = create_multiaxis_reducer (
539- elemwise_fn , scalar_op_identity , axes , ndim , acc_dtype , input_name = input_name
537+ elemwise_fn , scalar_op_identity , axes , ndim , np_acc_dtype , input_name = input_name
540538 )
541539
542540 return numba .njit (careduce_fn )
0 commit comments