diff options
author | Edoardo Pasca <edo.paskino@gmail.com> | 2018-02-21 10:49:34 +0000 |
---|---|---|
committer | Edoardo Pasca <edo.paskino@gmail.com> | 2018-02-21 10:49:34 +0000 |
commit | 26c0a07ea72d1caabcb9c7f73d00a32dff7c707e (patch) | |
tree | 17da0d546547e818d248b2b9dcef92aaeff8677d /Wrappers/Python | |
parent | 1f84f8da7500b4f442aa546247989f8b094e26d7 (diff) | |
download | framework-26c0a07ea72d1caabcb9c7f73d00a32dff7c707e.tar.gz framework-26c0a07ea72d1caabcb9c7f73d00a32dff7c707e.tar.bz2 framework-26c0a07ea72d1caabcb9c7f73d00a32dff7c707e.tar.xz framework-26c0a07ea72d1caabcb9c7f73d00a32dff7c707e.zip |
added sum
Diffstat (limited to 'Wrappers/Python')
-rw-r--r-- | Wrappers/Python/ccpi/framework.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Wrappers/Python/ccpi/framework.py b/Wrappers/Python/ccpi/framework.py index 3cfa2a0..fc1aa21 100644 --- a/Wrappers/Python/ccpi/framework.py +++ b/Wrappers/Python/ccpi/framework.py @@ -343,6 +343,9 @@ class DataSet(object): raise ValueError('Dimensions do not match') # __rpow__ + def sum(self): + return DataSet(self.as_array().sum(), + dimension_labels=self.dimension_labels) # in-place arithmetic operators: # (+=, -=, *=, /= , //=, |