mirror of
https://github.com/fjosw/pyerrors.git
synced 2025-05-14 19:43:41 +02:00
Added tag attribute to CObs, added __slots__ to CObs, decreasing memory
footprint
This commit is contained in:
parent
f3b1a2bf34
commit
040f6dbd51
1 changed files with 2 additions and 0 deletions
|
@ -641,9 +641,11 @@ class Obs:
|
|||
|
||||
|
||||
class CObs:
|
||||
__slots__ = ['real', 'imag', 'tag']
|
||||
def __init__(self, real, imag=0.0):
|
||||
self.real = real
|
||||
self.imag = imag
|
||||
self.tag = None
|
||||
|
||||
def gamma_method(self, **kwargs):
|
||||
if isinstance(self.real, Obs):
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue