padding arrays using numpy
There's a pad
module scheduled for inclusion in Numpy 1.7.0 – see this ticket. For now, just download it and use its with_constant
function.
Unpadding is as simple as field[1:-1, 1:-1]
.
There's a pad
module scheduled for inclusion in Numpy 1.7.0 – see this ticket. For now, just download it and use its with_constant
function.
Unpadding is as simple as field[1:-1, 1:-1]
.