This question is related to: How to apply a disc shaped mask to a numpy array?
From the solution: https://stackoverflow.com/a/8650741/4484153, is it possible to obtain circular mask in the following manner:
>>> new_arr
array([[ True, True, True, True, 1., 1., 1., True],
[ True, True, True, True, True, 1., True, True],
[ True, True, True, True, 1., 1., 1., True],
[ True, True, True, True, 1., 1., 1., True],
[ 1., True, 1., 1., 1., 1., 1., 1. ],
[ 1., 1., 1., 1., 1., 1., 1., 1. ],
[ 1., True, 1., 1., 1., 1., 1., 1. ],
[ True, True, True, True, 1., 1., 1., True]])
in such a way that the array wraps around its columns and rows?