File tree Expand file tree Collapse file tree 3 files changed +5
-5
lines changed Expand file tree Collapse file tree 3 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -479,7 +479,7 @@ def pytensor_hash(self):
479
479
return hash_from_sparse (d )
480
480
481
481
482
- class SparseConstant (TensorConstant , _sparse_py_operators ):
482
+ class SparseConstant (SparseVariable , TensorConstant ):
483
483
format = property (lambda self : self .type .format )
484
484
485
485
def signature (self ):
Original file line number Diff line number Diff line change 3
3
import scipy .sparse
4
4
5
5
from pytensor .compile import shared_constructor
6
- from pytensor .sparse .basic import SparseTensorType , _sparse_py_operators
6
+ from pytensor .sparse .basic import SparseTensorType , SparseVariable
7
7
from pytensor .tensor .sharedvar import TensorSharedVariable
8
8
9
9
10
- class SparseTensorSharedVariable (TensorSharedVariable , _sparse_py_operators ):
10
+ class SparseTensorSharedVariable (TensorSharedVariable , SparseVariable ):
11
11
@property
12
12
def format (self ):
13
13
return self .type .format
Original file line number Diff line number Diff line change 6
6
from pytensor .misc .safe_asarray import _asarray
7
7
from pytensor .tensor import _get_vector_length
8
8
from pytensor .tensor .type import TensorType
9
- from pytensor .tensor .variable import _tensor_py_operators
9
+ from pytensor .tensor .variable import TensorVariable
10
10
11
11
12
12
def __getattr__ (name ):
@@ -31,7 +31,7 @@ def load_shared_variable(val):
31
31
return tensor_constructor (val )
32
32
33
33
34
- class TensorSharedVariable (_tensor_py_operators , SharedVariable ):
34
+ class TensorSharedVariable (SharedVariable , TensorVariable ):
35
35
def zero (self , borrow : bool = False ):
36
36
r"""Set the values of a shared variable to 0.
37
37
You can’t perform that action at this time.
0 commit comments