larray.Session.items

Session.items()[source]

Returns a view of the session’s items ((key, value) pairs).

Returns:View on the session’s items.

Examples

>>> arr1, arr2, arr3 = ndtest((2, 2)), ndtest(4), ndtest((3, 2))
>>> # make the test pass on both Windows and Linux
>>> arr1, arr2, arr3 = arr1.astype(np.int64), arr2.astype(np.int64), arr3.astype(np.int64)
>>> s = Session([('arr2', arr2), ('arr1', arr1), ('arr3', arr3)])
>>> for k, v in s.items():
...     print("{}: {}".format(k, v.info))
arr2: 4
 a [4]: 'a0' 'a1' 'a2' 'a3'
dtype: int64
arr1: 2 x 2
 a [2]: 'a0' 'a1'
 b [2]: 'b0' 'b1'
dtype: int64
arr3: 3 x 2
 a [3]: 'a0' 'a1' 'a2'
 b [2]: 'b0' 'b1'
dtype: int64