def size(self, dim=0): if _swig_: if hasattr(self, 'file'): f = self.file else: f = c_rsf.sf_input(self.tag) s = c_rsf.sf_leftsize(f, dim) if not hasattr(self, 'file'): c_rsf.sf_fileclose(f) else: s = 1 for axis in range(dim + 1, 10): n = self.int("n%d" % axis) if n: s *= n else: break return s
def size(self,dim=0): if _swig_: if hasattr(self,'file'): f = self.file else: f = c_rsf.sf_input(self.tag) s = c_rsf.sf_leftsize(f,dim) if not hasattr(self,'file'): c_rsf.sf_fileclose(f) else: s = 1 for axis in range(dim+1,10): n = self.int("n%d" % axis) if n: s *= n else: break return s