pytensor 2.18.6__tar.gz → 2.20.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pytensor-2.18.6/pytensor.egg-info → pytensor-2.20.0}/PKG-INFO +13 -7
- {pytensor-2.18.6 → pytensor-2.20.0}/README.rst +9 -2
- {pytensor-2.18.6 → pytensor-2.20.0}/bin/__init__.py +1 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/environment.yml +1 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pyproject.toml +44 -91
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/__init__.py +1 -2
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/_version.py +4 -4
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/breakpoint.py +2 -2
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/compile/builders.py +39 -37
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/compile/compiledir.py +2 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/compile/compilelock.py +4 -2
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/compile/debugmode.py +9 -14
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/compile/function/__init__.py +2 -2
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/compile/function/pfunc.py +13 -17
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/compile/function/types.py +12 -12
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/compile/io.py +0 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/compile/mode.py +5 -5
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/compile/monitormode.py +1 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/compile/nanguardmode.py +3 -3
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/compile/ops.py +3 -3
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/compile/profiling.py +7 -7
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/compile/sharedvalue.py +7 -7
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/configdefaults.py +6 -3
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/configparser.py +5 -6
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/d3viz/d3viz.py +0 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/d3viz/formatting.py +3 -2
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/gradient.py +40 -40
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/graph/basic.py +83 -56
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/graph/destroyhandler.py +9 -9
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/graph/features.py +7 -5
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/graph/fg.py +24 -20
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/graph/op.py +14 -17
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/graph/replace.py +23 -29
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/graph/rewriting/basic.py +47 -48
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/graph/rewriting/db.py +18 -23
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/graph/rewriting/kanren.py +4 -6
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/graph/rewriting/unify.py +5 -6
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/graph/rewriting/utils.py +5 -5
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/graph/type.py +11 -13
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/graph/utils.py +7 -7
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/ifelse.py +25 -25
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/basic.py +18 -18
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/c/basic.py +69 -90
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/c/cmodule.py +32 -38
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/c/interface.py +15 -12
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/c/lazylinker_c.py +3 -4
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/c/op.py +25 -25
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/c/params_type.py +72 -76
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/c/type.py +64 -68
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/jax/dispatch/elemwise.py +7 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/jax/dispatch/nlinalg.py +2 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/jax/dispatch/random.py +1 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/jax/dispatch/scalar.py +3 -3
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/jax/dispatch/shape.py +1 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/jax/dispatch/tensor_basic.py +9 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/jax/linker.py +1 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/numba/dispatch/basic.py +13 -42
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/numba/dispatch/cython_support.py +4 -4
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/numba/dispatch/elemwise.py +7 -6
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/numba/dispatch/elemwise_codegen.py +2 -4
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/numba/dispatch/extra_ops.py +1 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/numba/dispatch/random.py +4 -11
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/numba/dispatch/scalar.py +1 -7
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/numba/dispatch/scan.py +4 -5
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/numba/dispatch/slinalg.py +140 -18
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/numba/dispatch/tensor_basic.py +3 -3
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/utils.py +15 -23
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/vm.py +8 -7
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/misc/may_share_memory.py +0 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/misc/ordered_set.py +2 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/misc/safe_asarray.py +0 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/printing.py +50 -56
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/raise_op.py +2 -2
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scalar/basic.py +52 -51
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scalar/c_code/gamma.c +10 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scalar/loop.py +2 -3
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scalar/math.py +40 -31
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scalar/sharedvar.py +1 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scan/__init__.py +0 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scan/basic.py +11 -11
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scan/op.py +33 -44
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scan/rewriting.py +30 -27
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scan/scan_perform_ext.py +2 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scan/utils.py +39 -31
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scan/views.py +1 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/sparse/__init__.py +1 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/sparse/basic.py +102 -101
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/sparse/rewriting.py +556 -576
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/sparse/sandbox/sp.py +4 -4
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/sparse/sharedvar.py +2 -2
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/sparse/type.py +7 -7
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/__init__.py +32 -32
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/basic.py +175 -201
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/blas.py +69 -81
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/blas_c.py +185 -188
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/blas_headers.py +25 -28
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/blockwise.py +8 -8
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/conv/abstract_conv.py +148 -125
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/elemwise.py +61 -86
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/elemwise_cgen.py +23 -25
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/extra_ops.py +75 -90
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/fft.py +1 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/fourier.py +10 -8
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/functional.py +3 -3
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/io.py +2 -4
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/math.py +136 -64
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/nlinalg.py +243 -31
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/random/basic.py +42 -11
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/random/op.py +27 -9
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/random/rewriting/basic.py +1 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/random/utils.py +36 -8
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/random/var.py +2 -4
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/rewriting/basic.py +47 -25
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/rewriting/blas.py +5 -7
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/rewriting/blockwise.py +9 -17
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/rewriting/elemwise.py +19 -18
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/rewriting/linalg.py +3 -3
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/rewriting/math.py +35 -36
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/rewriting/shape.py +9 -10
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/rewriting/special.py +1 -2
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/rewriting/subtensor.py +18 -20
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/shape.py +15 -12
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/sharedvar.py +16 -15
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/slinalg.py +16 -54
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/special.py +10 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/subtensor.py +244 -271
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/type.py +103 -118
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/type_other.py +1 -6
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/utils.py +7 -8
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/variable.py +7 -7
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/typed_list/basic.py +61 -83
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/typed_list/rewriting.py +1 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/typed_list/type.py +9 -14
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/updates.py +1 -2
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/utils.py +4 -4
- {pytensor-2.18.6 → pytensor-2.20.0/pytensor.egg-info}/PKG-INFO +13 -7
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor.egg-info/SOURCES.txt +0 -3
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor.egg-info/requires.txt +1 -2
- {pytensor-2.18.6 → pytensor-2.20.0}/scripts/mypy-failing.txt +0 -1
- pytensor-2.20.0/setup.cfg +4 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/tests/test_breakpoint.py +1 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/tests/test_config.py +1 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/tests/test_gradient.py +2 -3
- {pytensor-2.18.6 → pytensor-2.20.0}/tests/test_ifelse.py +4 -4
- {pytensor-2.18.6 → pytensor-2.20.0}/tests/test_printing.py +10 -6
- {pytensor-2.18.6 → pytensor-2.20.0}/tests/test_rop.py +0 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/versioneer.py +7 -7
- pytensor-2.18.6/scripts/downstream_pr.sh +0 -46
- pytensor-2.18.6/scripts/upstream_pr.sh +0 -43
- pytensor-2.18.6/setup.cfg +0 -29
- {pytensor-2.18.6 → pytensor-2.20.0}/LICENSE.txt +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/MANIFEST.in +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/bin/pytensor-cache +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/bin/pytensor_cache.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/.templates/PLACEHOLDER +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/.templates/layout.html +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/LICENSE.txt +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/README.md +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/acknowledgement.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/bcast.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/bcast.svg +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/conf.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/core_development_guide.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/css.inc +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/dev_start_guide.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/apply.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/apply.svg +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/apply2.svg +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/creating_a_c_op.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/creating_a_numba_jax_op.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/creating_an_op.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/ctype.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/extending_faq.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/extending_pytensor_solution_1.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/graph_rewriting.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/graphstructures.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/index.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/inplace.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/op.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/other_ops.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/pics/symbolic_graph_opt.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/pics/symbolic_graph_unopt.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/pipeline.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/scan.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/tips.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/type.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/unittest.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/extending/using_params.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/faq.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/generate_dtype_tensor_table.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/glossary.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/images/Elman_srnn.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/images/PyTensor_RGB.svg +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/images/blocksparse.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/images/lstm.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/images/lstm_memorycell.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/images/talk2010.gif +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/images/talk2010.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/index.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/install.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/internal/how_to_release.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/internal/index.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/internal/metadocumentation.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/introduction.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/compile/debugmode.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/compile/function.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/compile/index.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/compile/io.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/compile/mode.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/compile/nanguardmode.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/compile/opfromgraph.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/compile/ops.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/compile/profilemode.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/compile/shared.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/config.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/examples/d3viz/css/d3-context-menu.css +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/examples/d3viz/css/d3viz.css +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/examples/d3viz/js/d3-context-menu.js +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/examples/d3viz/js/d3.v3.min.js +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/examples/d3viz/js/d3viz.js +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/examples/d3viz/js/dagre-d3.min.js +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/examples/d3viz/js/graphlib-dot.min.js +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/examples/mlp.html +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/examples/mlp.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/examples/mlp2.html +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/examples/mlp2.pdf +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/examples/mlp2.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/examples/ofg.html +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/examples/ofg2.html +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/index.ipynb +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/index.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/index_files/index_10_0.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/index_files/index_11_0.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/index_files/index_24_0.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/d3viz/index_files/index_25_0.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/gradient.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/graph/features.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/graph/fgraph.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/graph/graph.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/graph/index.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/graph/op.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/graph/type.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/graph/utils.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/index.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/misc/pkl_utils.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/printing.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/sandbox/index.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/sandbox/linalg.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/scalar/index.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/scan.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/sparse/index.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/sparse/sandbox.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/basic.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/basic_opt.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/bcast.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/bcast.svg +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/conv.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/elemwise.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/extra_ops.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/fft.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/index.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/io.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/math_opt.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/nlinalg.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/plot_fft.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/random/basic.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/random/index.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/random/utils.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/slinalg.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/tensor/utils.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/library/typed_list.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/links.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/optimizations.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/pylintrc +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/ccodegen.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/compilation.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/debugging_with_stepmode.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/elemwise_compiler.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/function.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/functional.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/how_to_make_ops.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/index.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/index2.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/interactive_debugger.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/logistic_regression_example.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/performance.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/randomnumbers.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/rethinkccodegen.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/sandbox.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/software.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/sparse.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/sandbox/tensoroptools.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/scripts/docgen.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/troubleshooting.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/adding.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/adding_solution_1.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/aliasing.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/apply.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/apply.svg +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/bcast.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/broadcasting.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/conditions.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/debug_faq.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/dlogistic.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/examples.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/faq_tutorial.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/gradients.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/index.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/loading_and_saving.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/logistic.gp +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/logistic.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/loop.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/loop_solution_1.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/modes.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/modes_solution_1.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/multi_cores.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/nan_tutorial.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/pics/d3viz.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/pics/logreg_pydotprint_predict.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/pics/logreg_pydotprint_prediction.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/pics/logreg_pydotprint_train.png +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/printing_drawing.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/profiling.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/profiling_example.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/profiling_example_out.prof +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/shape_info.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/sparse.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/tutorial/symbolic_graphs.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/doc/user_guide.rst +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/bin/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/bin/pytensor_cache.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/compile/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/d3viz/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/d3viz/css/d3-context-menu.css +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/d3viz/css/d3viz.css +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/d3viz/js/d3-context-menu.js +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/d3viz/js/d3.v3.min.js +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/d3viz/js/d3viz.js +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/d3viz/js/dagre-d3.min.js +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/d3viz/js/graphlib-dot.min.js +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/graph/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/graph/null_type.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/graph/rewriting/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/c/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/c/c_code/lazylinker_c.c +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/c/c_code/pytensor_mod_helper.h +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/c/cutils.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/c/cvm.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/c/exceptions.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/jax/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/jax/dispatch/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/jax/dispatch/basic.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/jax/dispatch/blockwise.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/jax/dispatch/extra_ops.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/jax/dispatch/scan.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/jax/dispatch/slinalg.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/jax/dispatch/sparse.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/jax/dispatch/subtensor.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/numba/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/numba/dispatch/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/numba/dispatch/nlinalg.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/numba/dispatch/sparse.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/link/numba/linker.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/misc/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/misc/check_blas.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/misc/check_blas_many.sh +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/misc/check_duplicate_key.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/misc/elemwise_openmp_speedup.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/misc/elemwise_time_test.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/misc/frozendict.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/misc/pkl_utils.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/py.typed +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scalar/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scalar/c_code/Faddeeva.cc +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scalar/c_code/Faddeeva.hh +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scan/checkpoints.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/scan/scan_perform.pyx +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/sparse/sandbox/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/sparse/sandbox/sp2.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/sparse/utils.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/blas_scipy.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/c_code/alt_blas_common.h +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/c_code/alt_blas_template.c +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/c_code/dimshuffle.c +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/conv/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/exceptions.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/inplace.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/linalg.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/random/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/random/rewriting/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/random/rewriting/jax.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/random/type.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/rewriting/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/rewriting/blas_c.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/rewriting/blas_scipy.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/rewriting/extra_ops.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/rewriting/jax.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/rewriting/uncanonicalize.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/sort.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/var.py +1 -1
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/tensor/xlogx.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/typed_list/__init__.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor/version.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor.egg-info/dependency_links.txt +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor.egg-info/entry_points.txt +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/pytensor.egg-info/top_level.txt +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/setup.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/tests/link/c/c_code/test_cenum.h +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/tests/link/c/c_code/test_quadratic_function.c +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/tests/tensor/conv/c_code/corr3d_gemm.c +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/tests/tensor/conv/c_code/corr_gemm.c +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/tests/test_raise_op.py +0 -0
- {pytensor-2.18.6 → pytensor-2.20.0}/tests/test_updates.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: pytensor
|
|
3
|
-
Version: 2.
|
|
3
|
+
Version: 2.20.0
|
|
4
4
|
Summary: Optimizing compiler for evaluating mathematical expressions on CPUs and GPUs.
|
|
5
5
|
Author-email: pymc-devs <pymc.devs@gmail.com>
|
|
6
6
|
License: .. _license:
|
|
@@ -66,10 +66,10 @@ Classifier: Operating System :: POSIX
|
|
|
66
66
|
Classifier: Operating System :: Unix
|
|
67
67
|
Classifier: Operating System :: MacOS
|
|
68
68
|
Classifier: Programming Language :: Python :: 3
|
|
69
|
-
Classifier: Programming Language :: Python :: 3.9
|
|
70
69
|
Classifier: Programming Language :: Python :: 3.10
|
|
71
70
|
Classifier: Programming Language :: Python :: 3.11
|
|
72
|
-
|
|
71
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
72
|
+
Requires-Python: <3.13,>=3.10
|
|
73
73
|
Description-Content-Type: text/x-rst
|
|
74
74
|
License-File: LICENSE.txt
|
|
75
75
|
Requires-Dist: setuptools>=48.0.0
|
|
@@ -105,8 +105,7 @@ Provides-Extra: jax
|
|
|
105
105
|
Requires-Dist: jax; extra == "jax"
|
|
106
106
|
Requires-Dist: jaxlib; extra == "jax"
|
|
107
107
|
Provides-Extra: numba
|
|
108
|
-
Requires-Dist: numba>=0.
|
|
109
|
-
Requires-Dist: numba-scipy>=0.3.0; extra == "numba"
|
|
108
|
+
Requires-Dist: numba>=0.57; extra == "numba"
|
|
110
109
|
|
|
111
110
|
.. image:: https://cdn.rawgit.com/pymc-devs/pytensor/main/doc/images/PyTensor_RGB.svg
|
|
112
111
|
:height: 100px
|
|
@@ -115,8 +114,9 @@ Requires-Dist: numba-scipy>=0.3.0; extra == "numba"
|
|
|
115
114
|
|
|
116
115
|
|Tests Status| |Coverage|
|
|
117
116
|
|
|
118
|
-
|Project Name| is a
|
|
117
|
+
|Project Name| is a Python library that allows one to define, optimize, and
|
|
119
118
|
efficiently evaluate mathematical expressions involving multi-dimensional arrays.
|
|
119
|
+
It provides the computational backend for `PyMC <https://github.com/pymc-devs/pymc>`__.
|
|
120
120
|
|
|
121
121
|
Features
|
|
122
122
|
========
|
|
@@ -125,7 +125,8 @@ Features
|
|
|
125
125
|
- Extensible graph framework suitable for rapid development of custom operators and symbolic optimizations
|
|
126
126
|
- Implements an extensible graph transpilation framework that currently provides
|
|
127
127
|
compilation via C, `JAX <https://github.com/google/jax>`__, and `Numba <https://github.com/numba/numba>`__
|
|
128
|
-
-
|
|
128
|
+
- Contrary to PyTorch and TensorFlow, PyTensor maintains a static graph which can be modified in-place to
|
|
129
|
+
allow for advanced optimizations
|
|
129
130
|
|
|
130
131
|
Getting started
|
|
131
132
|
===============
|
|
@@ -223,6 +224,11 @@ The current development branch of |Project Name| can be installed from GitHub, a
|
|
|
223
224
|
pip install git+https://github.com/pymc-devs/pytensor
|
|
224
225
|
|
|
225
226
|
|
|
227
|
+
Background
|
|
228
|
+
==========
|
|
229
|
+
|
|
230
|
+
PyTensor is a fork of `Aesara <https://github.com/aesara-devs/aesara>`__, which is a fork of `Theano <https://github.com/Theano/Theano>`__.
|
|
231
|
+
|
|
226
232
|
Contributing
|
|
227
233
|
============
|
|
228
234
|
|
|
@@ -5,8 +5,9 @@
|
|
|
5
5
|
|
|
6
6
|
|Tests Status| |Coverage|
|
|
7
7
|
|
|
8
|
-
|Project Name| is a
|
|
8
|
+
|Project Name| is a Python library that allows one to define, optimize, and
|
|
9
9
|
efficiently evaluate mathematical expressions involving multi-dimensional arrays.
|
|
10
|
+
It provides the computational backend for `PyMC <https://github.com/pymc-devs/pymc>`__.
|
|
10
11
|
|
|
11
12
|
Features
|
|
12
13
|
========
|
|
@@ -15,7 +16,8 @@ Features
|
|
|
15
16
|
- Extensible graph framework suitable for rapid development of custom operators and symbolic optimizations
|
|
16
17
|
- Implements an extensible graph transpilation framework that currently provides
|
|
17
18
|
compilation via C, `JAX <https://github.com/google/jax>`__, and `Numba <https://github.com/numba/numba>`__
|
|
18
|
-
-
|
|
19
|
+
- Contrary to PyTorch and TensorFlow, PyTensor maintains a static graph which can be modified in-place to
|
|
20
|
+
allow for advanced optimizations
|
|
19
21
|
|
|
20
22
|
Getting started
|
|
21
23
|
===============
|
|
@@ -113,6 +115,11 @@ The current development branch of |Project Name| can be installed from GitHub, a
|
|
|
113
115
|
pip install git+https://github.com/pymc-devs/pytensor
|
|
114
116
|
|
|
115
117
|
|
|
118
|
+
Background
|
|
119
|
+
==========
|
|
120
|
+
|
|
121
|
+
PyTensor is a fork of `Aesara <https://github.com/aesara-devs/aesara>`__, which is a fork of `Theano <https://github.com/Theano/Theano>`__.
|
|
122
|
+
|
|
116
123
|
Contributing
|
|
117
124
|
============
|
|
118
125
|
|
|
@@ -1,24 +1,20 @@
|
|
|
1
1
|
[build-system]
|
|
2
2
|
requires = [
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
3
|
+
"setuptools>=48.0.0",
|
|
4
|
+
"cython",
|
|
5
|
+
"numpy>=1.17.0",
|
|
6
|
+
"versioneer[toml]>=0.28",
|
|
7
7
|
]
|
|
8
8
|
build-backend = "setuptools.build_meta"
|
|
9
9
|
|
|
10
10
|
[project]
|
|
11
11
|
name = "pytensor"
|
|
12
|
-
dynamic = [
|
|
13
|
-
|
|
14
|
-
]
|
|
15
|
-
requires-python = ">=3.9,<3.12"
|
|
16
|
-
authors = [
|
|
17
|
-
{name = "pymc-devs", email = "pymc.devs@gmail.com"}
|
|
18
|
-
]
|
|
12
|
+
dynamic = ['version']
|
|
13
|
+
requires-python = ">=3.10,<3.13"
|
|
14
|
+
authors = [{ name = "pymc-devs", email = "pymc.devs@gmail.com" }]
|
|
19
15
|
description = "Optimizing compiler for evaluating mathematical expressions on CPUs and GPUs."
|
|
20
16
|
readme = "README.rst"
|
|
21
|
-
license = {file = "LICENSE.txt"}
|
|
17
|
+
license = { file = "LICENSE.txt" }
|
|
22
18
|
classifiers = [
|
|
23
19
|
"Development Status :: 6 - Mature",
|
|
24
20
|
"Intended Audience :: Education",
|
|
@@ -34,9 +30,9 @@ classifiers = [
|
|
|
34
30
|
"Operating System :: Unix",
|
|
35
31
|
"Operating System :: MacOS",
|
|
36
32
|
"Programming Language :: Python :: 3",
|
|
37
|
-
"Programming Language :: Python :: 3.9",
|
|
38
33
|
"Programming Language :: Python :: 3.10",
|
|
39
34
|
"Programming Language :: Python :: 3.11",
|
|
35
|
+
"Programming Language :: Python :: 3.12",
|
|
40
36
|
]
|
|
41
37
|
|
|
42
38
|
keywords = [
|
|
@@ -71,15 +67,8 @@ documentation = "https://pytensor.readthedocs.io/en/latest/"
|
|
|
71
67
|
pytensor-cache = "pytensor.bin.pytensor_cache:main"
|
|
72
68
|
|
|
73
69
|
[project.optional-dependencies]
|
|
74
|
-
complete = [
|
|
75
|
-
|
|
76
|
-
"pytensor[numba]",
|
|
77
|
-
]
|
|
78
|
-
development = [
|
|
79
|
-
"pytensor[complete]",
|
|
80
|
-
"pytensor[tests]",
|
|
81
|
-
"pytensor[rtd]"
|
|
82
|
-
]
|
|
70
|
+
complete = ["pytensor[jax]", "pytensor[numba]"]
|
|
71
|
+
development = ["pytensor[complete]", "pytensor[tests]", "pytensor[rtd]"]
|
|
83
72
|
tests = [
|
|
84
73
|
"pytest",
|
|
85
74
|
"pre-commit",
|
|
@@ -88,34 +77,16 @@ tests = [
|
|
|
88
77
|
"pytest-benchmark",
|
|
89
78
|
"pytest-mock",
|
|
90
79
|
]
|
|
91
|
-
rtd = [
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
"pydot",
|
|
95
|
-
"pydot2",
|
|
96
|
-
"pydot-ng",
|
|
97
|
-
]
|
|
98
|
-
jax = [
|
|
99
|
-
"jax",
|
|
100
|
-
"jaxlib",
|
|
101
|
-
]
|
|
102
|
-
numba = [
|
|
103
|
-
"numba>=0.55",
|
|
104
|
-
"numba-scipy>=0.3.0"
|
|
105
|
-
]
|
|
80
|
+
rtd = ["sphinx>=5.1.0,<6", "pygments", "pydot", "pydot2", "pydot-ng"]
|
|
81
|
+
jax = ["jax", "jaxlib"]
|
|
82
|
+
numba = ["numba>=0.57"]
|
|
106
83
|
|
|
107
84
|
[tool.setuptools.packages.find]
|
|
108
85
|
include = ["pytensor*", "bin"]
|
|
109
86
|
|
|
110
87
|
[tool.setuptools.package-data]
|
|
111
|
-
pytensor = [
|
|
112
|
-
|
|
113
|
-
]
|
|
114
|
-
"pytensor.d3viz" = [
|
|
115
|
-
"html/*",
|
|
116
|
-
"css/*",
|
|
117
|
-
"js/*",
|
|
118
|
-
]
|
|
88
|
+
pytensor = ["py.typed"]
|
|
89
|
+
"pytensor.d3viz" = ["html/*", "css/*", "js/*"]
|
|
119
90
|
|
|
120
91
|
[tool.coverage.run]
|
|
121
92
|
omit = [
|
|
@@ -129,21 +100,13 @@ omit = [
|
|
|
129
100
|
"pytensor/graph/unify.py",
|
|
130
101
|
"pytensor/link/jax/jax_linker.py",
|
|
131
102
|
"pytensor/link/jax/jax_dispatch.py",
|
|
132
|
-
"pytensor/graph/toolbox.py",
|
|
133
|
-
"pytensor/scalar/basic_scipy.py",
|
|
134
103
|
]
|
|
135
104
|
branch = true
|
|
136
105
|
relative_files = true
|
|
137
106
|
|
|
138
107
|
[tool.coverage.report]
|
|
139
|
-
omit = [
|
|
140
|
-
|
|
141
|
-
"tests/",
|
|
142
|
-
]
|
|
143
|
-
exclude_lines = [
|
|
144
|
-
"pragma: no cover",
|
|
145
|
-
"if TYPE_CHECKING:",
|
|
146
|
-
]
|
|
108
|
+
omit = ["pytensor/_version.py", "tests/"]
|
|
109
|
+
exclude_lines = ["pragma: no cover", "if TYPE_CHECKING:"]
|
|
147
110
|
show_missing = true
|
|
148
111
|
|
|
149
112
|
[tool.versioneer]
|
|
@@ -157,50 +120,40 @@ tag_prefix = "rel-"
|
|
|
157
120
|
addopts = "--durations=50"
|
|
158
121
|
testpaths = "tests/"
|
|
159
122
|
|
|
160
|
-
[tool.
|
|
161
|
-
|
|
123
|
+
[tool.ruff]
|
|
124
|
+
line-length = 88
|
|
125
|
+
exclude = ["doc/", "pytensor/_version.py", "bin/pytensor_cache.py"]
|
|
162
126
|
|
|
163
|
-
[tool.
|
|
164
|
-
|
|
127
|
+
[tool.ruff.lint]
|
|
128
|
+
select = ["C", "E", "F", "I", "UP", "W", "RUF"]
|
|
129
|
+
ignore = ["C408", "C901", "E501", "E741", "RUF012"]
|
|
165
130
|
|
|
166
|
-
[tool.isort]
|
|
167
|
-
profile = "black"
|
|
168
|
-
lines_after_imports = 2
|
|
169
|
-
lines_between_sections = 1
|
|
170
|
-
honor_noqa = true
|
|
171
|
-
skip_gitignore = true
|
|
172
|
-
skip = "pytensor/version.py"
|
|
173
|
-
skip_glob = "**/*.pyx"
|
|
174
131
|
|
|
175
|
-
[tool.ruff]
|
|
176
|
-
|
|
177
|
-
ignore=["E501","E741","C408","C901"]
|
|
178
|
-
exclude = [
|
|
179
|
-
"doc/",
|
|
180
|
-
"pytensor/_version.py",
|
|
181
|
-
"bin/pytensor_cache.py",
|
|
182
|
-
]
|
|
132
|
+
[tool.ruff.lint.isort]
|
|
133
|
+
lines-after-imports = 2
|
|
183
134
|
|
|
184
|
-
[tool.ruff.per-file-ignores]
|
|
135
|
+
[tool.ruff.lint.per-file-ignores]
|
|
185
136
|
# TODO: Get rid of these:
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
137
|
+
"**/__init__.py" = ["F401", "E402", "F403"]
|
|
138
|
+
"pytensor/tensor/linalg.py" = ["F403"]
|
|
139
|
+
# For the tests we skip because `pytest.importorskip` is used:
|
|
140
|
+
"tests/link/jax/test_scalar.py" = ["E402"]
|
|
141
|
+
"tests/link/jax/test_tensor_basic.py" = ["E402"]
|
|
142
|
+
"tests/link/numba/test_basic.py" = ["E402"]
|
|
143
|
+
"tests/link/numba/test_cython_support.py" = ["E402"]
|
|
144
|
+
"tests/link/numba/test_performance.py" = ["E402"]
|
|
145
|
+
"tests/link/numba/test_sparse.py" = ["E402"]
|
|
146
|
+
"tests/link/numba/test_tensor_basic.py" = ["E402"]
|
|
147
|
+
"tests/tensor/test_math_scipy.py" = ["E402"]
|
|
148
|
+
"tests/sparse/test_basic.py" = ["E402"]
|
|
149
|
+
"tests/sparse/test_sp2.py" = ["E402"]
|
|
150
|
+
"tests/sparse/test_utils.py" = ["E402"]
|
|
151
|
+
"tests/sparse/sandbox/test_sp.py" = ["E402", "F401"]
|
|
152
|
+
"versioneer.py" = ["I"]
|
|
201
153
|
|
|
202
154
|
|
|
203
155
|
[tool.mypy]
|
|
156
|
+
python_version = "3.10"
|
|
204
157
|
ignore_missing_imports = true
|
|
205
158
|
no_implicit_optional = true
|
|
206
159
|
check_untyped_defs = false
|
|
@@ -18,7 +18,6 @@ To learn more, check out:
|
|
|
18
18
|
|
|
19
19
|
"""
|
|
20
20
|
|
|
21
|
-
|
|
22
21
|
__docformat__ = "restructuredtext en"
|
|
23
22
|
|
|
24
23
|
# Set a default logger. It is important to do this before importing some other
|
|
@@ -77,7 +76,7 @@ from pytensor.graph.replace import clone_replace, graph_replace
|
|
|
77
76
|
# isort: on
|
|
78
77
|
|
|
79
78
|
|
|
80
|
-
def as_symbolic(x: Any, name:
|
|
79
|
+
def as_symbolic(x: Any, name: str | None = None, **kwargs) -> Variable:
|
|
81
80
|
"""Convert `x` into an equivalent PyTensor `Variable`.
|
|
82
81
|
|
|
83
82
|
Parameters
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
# This file was generated by 'versioneer.py' (0.
|
|
2
|
+
# This file was generated by 'versioneer.py' (0.29) from
|
|
3
3
|
# revision-control system data, or from the parent directory name of an
|
|
4
4
|
# unpacked source archive. Distribution tarballs contain a pre-generated copy
|
|
5
5
|
# of this file.
|
|
@@ -8,11 +8,11 @@ import json
|
|
|
8
8
|
|
|
9
9
|
version_json = '''
|
|
10
10
|
{
|
|
11
|
-
"date": "2024-
|
|
11
|
+
"date": "2024-03-28T18:19:27+0100",
|
|
12
12
|
"dirty": false,
|
|
13
13
|
"error": null,
|
|
14
|
-
"full-revisionid": "
|
|
15
|
-
"version": "2.
|
|
14
|
+
"full-revisionid": "ef22377d7e6ea6c74c36a8dc634ef7f1f1f8f9c6",
|
|
15
|
+
"version": "2.20.0"
|
|
16
16
|
}
|
|
17
17
|
''' # END VERSION_JSON
|
|
18
18
|
|
|
@@ -92,7 +92,7 @@ class PdbBreakpoint(Op):
|
|
|
92
92
|
new_op.inp_types.append(monitored_vars[i].type)
|
|
93
93
|
|
|
94
94
|
# Build the Apply node
|
|
95
|
-
inputs = [condition
|
|
95
|
+
inputs = [condition, *monitored_vars]
|
|
96
96
|
outputs = [inp.type() for inp in monitored_vars]
|
|
97
97
|
return Apply(op=new_op, inputs=inputs, outputs=outputs)
|
|
98
98
|
|
|
@@ -142,7 +142,7 @@ class PdbBreakpoint(Op):
|
|
|
142
142
|
output_storage[i][0] = inputs[i + 1]
|
|
143
143
|
|
|
144
144
|
def grad(self, inputs, output_gradients):
|
|
145
|
-
return [DisconnectedType()()
|
|
145
|
+
return [DisconnectedType()(), *output_gradients]
|
|
146
146
|
|
|
147
147
|
def infer_shape(self, fgraph, inputs, input_shapes):
|
|
148
148
|
# Return the shape of every input but the condition (first input)
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
"""Define new Ops from existing Ops"""
|
|
2
|
+
|
|
2
3
|
from collections import OrderedDict
|
|
3
4
|
from collections.abc import Sequence
|
|
4
5
|
from copy import copy
|
|
5
6
|
from functools import partial
|
|
6
|
-
from typing import
|
|
7
|
+
from typing import cast
|
|
7
8
|
|
|
8
9
|
import pytensor.tensor as pt
|
|
9
10
|
from pytensor import function
|
|
@@ -91,38 +92,29 @@ def construct_nominal_fgraph(
|
|
|
91
92
|
dict[Variable, Variable],
|
|
92
93
|
]:
|
|
93
94
|
"""Construct an inner-`FunctionGraph` with ordered nominal inputs."""
|
|
94
|
-
|
|
95
|
-
for n, inp in enumerate(inputs):
|
|
96
|
-
if (
|
|
97
|
-
not isinstance(inp, Variable)
|
|
98
|
-
or isinstance(inp, Constant)
|
|
99
|
-
or isinstance(inp, SharedVariable)
|
|
100
|
-
):
|
|
101
|
-
raise TypeError(
|
|
102
|
-
f"Inputs and outputs must be non-Constant/shared Variable instances; got {inp}"
|
|
103
|
-
)
|
|
95
|
+
implicit_shared_inputs = []
|
|
104
96
|
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
dummy_shared_inputs = []
|
|
108
|
-
shared_inputs = []
|
|
97
|
+
dummy_inputs = [inp.type() for inp in inputs]
|
|
98
|
+
dummy_implicit_shared_inputs = []
|
|
109
99
|
for var in graph_inputs(outputs, inputs):
|
|
100
|
+
if var in inputs:
|
|
101
|
+
continue
|
|
110
102
|
if isinstance(var, SharedVariable):
|
|
111
|
-
#
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
103
|
+
# We allow shared inputs to be added automatically to the graph
|
|
104
|
+
implicit_shared_inputs.append(var)
|
|
105
|
+
dummy_implicit_shared_inputs.append(var.type())
|
|
106
|
+
elif not isinstance(var, Constant):
|
|
107
|
+
raise MissingInputError(f"NominalGraph is missing an input: {var}")
|
|
108
|
+
|
|
109
|
+
replacements = dict(
|
|
110
|
+
zip(
|
|
111
|
+
inputs + implicit_shared_inputs, dummy_inputs + dummy_implicit_shared_inputs
|
|
112
|
+
)
|
|
113
|
+
)
|
|
122
114
|
|
|
123
115
|
new = rebuild_collect_shared(
|
|
124
116
|
cast(Sequence[Variable], outputs),
|
|
125
|
-
inputs=inputs +
|
|
117
|
+
inputs=inputs + implicit_shared_inputs,
|
|
126
118
|
replace=replacements,
|
|
127
119
|
copy_inputs_over=False,
|
|
128
120
|
)
|
|
@@ -132,7 +124,7 @@ def construct_nominal_fgraph(
|
|
|
132
124
|
(clone_d, update_d, update_expr, new_shared_inputs),
|
|
133
125
|
) = new
|
|
134
126
|
|
|
135
|
-
assert len(local_inputs) == len(inputs) + len(
|
|
127
|
+
assert len(local_inputs) == len(inputs) + len(implicit_shared_inputs)
|
|
136
128
|
assert len(local_outputs) == len(outputs)
|
|
137
129
|
assert not update_d
|
|
138
130
|
assert not update_expr
|
|
@@ -154,7 +146,7 @@ def construct_nominal_fgraph(
|
|
|
154
146
|
fgraph.clients.pop(inp, None)
|
|
155
147
|
fgraph.add_input(nom_inp)
|
|
156
148
|
|
|
157
|
-
return fgraph,
|
|
149
|
+
return fgraph, implicit_shared_inputs, update_d, update_expr
|
|
158
150
|
|
|
159
151
|
|
|
160
152
|
class OpFromGraph(Op, HasInnerGraph):
|
|
@@ -176,8 +168,6 @@ class OpFromGraph(Op, HasInnerGraph):
|
|
|
176
168
|
- grad() make it support DisconnectedType and the new interface
|
|
177
169
|
- add support for NullType and DisconnectedType when R_op supports them
|
|
178
170
|
- check how it works with updates.
|
|
179
|
-
- add test with constant as input or inside the inner graph.
|
|
180
|
-
- Add support for the GPU? Probably just need an opt to remove transfer
|
|
181
171
|
- Add support to pickle this Op.
|
|
182
172
|
- Add support/test with random generator
|
|
183
173
|
- Add optimization to removing unused inputs/outputs
|
|
@@ -285,7 +275,7 @@ class OpFromGraph(Op, HasInnerGraph):
|
|
|
285
275
|
#
|
|
286
276
|
# For now, this converts NullType or DisconnectedType into zeros_like.
|
|
287
277
|
# other types are unmodified: overrider_var -> None
|
|
288
|
-
if isinstance(grad.type,
|
|
278
|
+
if isinstance(grad.type, NullType | DisconnectedType):
|
|
289
279
|
if hasattr(inp, "zeros_like"):
|
|
290
280
|
return inp.zeros_like(), grad
|
|
291
281
|
else:
|
|
@@ -309,12 +299,14 @@ class OpFromGraph(Op, HasInnerGraph):
|
|
|
309
299
|
self,
|
|
310
300
|
inputs: list[Variable],
|
|
311
301
|
outputs: list[Variable],
|
|
302
|
+
*,
|
|
312
303
|
inline: bool = False,
|
|
313
304
|
lop_overrides: str = "default",
|
|
314
305
|
grad_overrides: str = "default",
|
|
315
306
|
rop_overrides: str = "default",
|
|
316
|
-
connection_pattern:
|
|
317
|
-
|
|
307
|
+
connection_pattern: list[list[bool]] | None = None,
|
|
308
|
+
strict: bool = False,
|
|
309
|
+
name: str | None = None,
|
|
318
310
|
**kwargs,
|
|
319
311
|
):
|
|
320
312
|
"""
|
|
@@ -398,6 +390,10 @@ class OpFromGraph(Op, HasInnerGraph):
|
|
|
398
390
|
must be equal to number of outputs. connection_pattern If not
|
|
399
391
|
``None``, this will be used as the connection_pattern for this
|
|
400
392
|
:class:`Op`.
|
|
393
|
+
strict: bool, default False
|
|
394
|
+
If true, it raises when any variables needed to compute the inner graph
|
|
395
|
+
are not provided as explici inputs. This can only happen for graphs with
|
|
396
|
+
shared variables.
|
|
401
397
|
name
|
|
402
398
|
A name for debugging purposes.
|
|
403
399
|
kwargs
|
|
@@ -423,6 +419,12 @@ class OpFromGraph(Op, HasInnerGraph):
|
|
|
423
419
|
inputs, outputs
|
|
424
420
|
)
|
|
425
421
|
|
|
422
|
+
if strict and self.shared_inputs:
|
|
423
|
+
raise ValueError(
|
|
424
|
+
"All variables needed to compute inner-graph must be provided as inputs under strict=True. "
|
|
425
|
+
f"The inner-graph implicitly depends on the following shared variables {self.shared_inputs}"
|
|
426
|
+
)
|
|
427
|
+
|
|
426
428
|
self.kwargs = kwargs
|
|
427
429
|
self.input_types = [inp.type for inp in inputs]
|
|
428
430
|
self.output_types = [out.type for out in outputs]
|
|
@@ -465,7 +467,7 @@ class OpFromGraph(Op, HasInnerGraph):
|
|
|
465
467
|
def __str__(self):
|
|
466
468
|
name = self.__class__.__name__ if self.name is None else self.name
|
|
467
469
|
is_inline = self.is_inline
|
|
468
|
-
return "
|
|
470
|
+
return "{name}{{inline={is_inline}}}".format(**locals())
|
|
469
471
|
|
|
470
472
|
@config.change_flags(compute_test_value="off")
|
|
471
473
|
def _recompute_lop_op(self):
|
|
@@ -533,7 +535,7 @@ class OpFromGraph(Op, HasInnerGraph):
|
|
|
533
535
|
all_grads_l = list(all_grads_l)
|
|
534
536
|
all_grads_ov_l = list(all_grads_ov_l)
|
|
535
537
|
elif isinstance(lop_op, Variable):
|
|
536
|
-
if isinstance(lop_op.type,
|
|
538
|
+
if isinstance(lop_op.type, DisconnectedType | NullType):
|
|
537
539
|
all_grads_l = [inp.zeros_like() for inp in local_inputs]
|
|
538
540
|
all_grads_ov_l = [lop_op.type() for _ in range(inp_len)]
|
|
539
541
|
else:
|
|
@@ -560,7 +562,7 @@ class OpFromGraph(Op, HasInnerGraph):
|
|
|
560
562
|
all_grads_l.append(gnext)
|
|
561
563
|
all_grads_ov_l.append(gnext_ov)
|
|
562
564
|
elif isinstance(fn_gov, Variable):
|
|
563
|
-
if isinstance(fn_gov.type,
|
|
565
|
+
if isinstance(fn_gov.type, DisconnectedType | NullType):
|
|
564
566
|
all_grads_l.append(inp.zeros_like())
|
|
565
567
|
all_grads_ov_l.append(fn_gov.type())
|
|
566
568
|
else:
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
This module contains housekeeping functions for cleaning/purging the "compiledir".
|
|
3
3
|
It is used by the "pytensor-cache" CLI tool, located in the /bin folder of the repository.
|
|
4
4
|
"""
|
|
5
|
+
|
|
5
6
|
import logging
|
|
6
7
|
import os
|
|
7
8
|
import pickle
|
|
@@ -54,7 +55,7 @@ def cleanup():
|
|
|
54
55
|
have_npy_abi_version = True
|
|
55
56
|
elif obj.startswith("c_compiler_str="):
|
|
56
57
|
have_c_compiler = True
|
|
57
|
-
elif isinstance(obj,
|
|
58
|
+
elif isinstance(obj, Op | CType) and hasattr(
|
|
58
59
|
obj, "c_code_cache_version"
|
|
59
60
|
):
|
|
60
61
|
v = obj.c_code_cache_version()
|
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
Locking mechanism to ensure no two compilations occur simultaneously
|
|
3
3
|
in the same compilation directory (which can cause crashes).
|
|
4
4
|
"""
|
|
5
|
+
|
|
5
6
|
import os
|
|
6
7
|
import threading
|
|
7
8
|
from contextlib import contextmanager
|
|
8
|
-
from typing import Optional, Union
|
|
9
9
|
|
|
10
10
|
import filelock
|
|
11
11
|
|
|
@@ -46,7 +46,9 @@ def force_unlock(lock_dir: os.PathLike):
|
|
|
46
46
|
|
|
47
47
|
@contextmanager
|
|
48
48
|
def lock_ctx(
|
|
49
|
-
lock_dir:
|
|
49
|
+
lock_dir: str | os.PathLike | None = None,
|
|
50
|
+
*,
|
|
51
|
+
timeout: float | None = None,
|
|
50
52
|
):
|
|
51
53
|
"""Context manager that wraps around FileLock and SoftFileLock from filelock package.
|
|
52
54
|
|