# Setting pixel values behaves differently on different machines.

I wanted to get left half, right half of image with original size. I used the code below. It works in some machine. In other the full image is cleared.

```
> h, w =drimg.shape
> limg=drimg[0:h, 0:w]
> rimg=drimg[0:h, 0:w]
> for j in range(h):
> for i in range(int(w/2),w):
> limg[j][i]=255
> for j in range(h):
> for i in range(0,int(w/2)):
rimg[j][i]=255
```

that's the "expected output".

btw: downvoted for: you're asking in the wrong place. python/numpy problem (slices !), not an opencv one at all

I may be wrong but isn't an image represented as a n- dimensional numpy array in opencv python? ^^ But slicing is python specific indeed.