@@ -129,13 +129,15 @@ def get_jit_compiled_integrate(
129
129
self ._check_inputs (dim = dim , N = N , integration_domain = integration_domain )
130
130
integration_domain = _setup_integration_domain (dim , integration_domain , backend )
131
131
backend = infer_backend (integration_domain )
132
- # autoray's autojit function does JIT compilation, too, but in its
133
- # current version it does not abstract away the differences between
134
- # backends enough for our purposes,
135
- # e.g. with PyTorch the to-be-compiled function cannot have keyword
136
- # arguments and all its positional arguments are considered
137
- # to be variable inputs for the compiled function.
138
- # https://github.com/jcmgray/autoray/blob/35677037863d7d0d25ff025998d9fda75dce3b44/autoray/compiler.py
132
+ # autoray's autojit function does JIT compilation, too.
133
+ # We don't use it here for the following reasons:
134
+ # * The way random number generators have to be included or excluded
135
+ # from compilation differs between backends.
136
+ # * autojit is not yet included in the latest autoray release
137
+ # (which is version 0.2.5).
138
+ # * It uses the deprecated experimental_compile argument with Tensorflow.
139
+ # * Additional detach() calls against warnings with PyTorch are not yet
140
+ # included in autojit.
139
141
if backend == "tensorflow" :
140
142
if not hasattr (self , "_tf_jit_calculate_sample_points" ):
141
143
import tensorflow as tf
0 commit comments