

def generic_wrap(self, expr, **kw):
    try:
        x = np.array(eval(expr, kw))
        try:
            desired = x.shape
        except:
            desired = np.zeros(())
    except:
        desired = 'failed'
    self.generic_check(expr, desired, **kw)

dataset/ETHPy150Open scipy/scipy/scipy/weave/tests/test_size_check.py TestExpressions.generic_wrap/original