Split 4-channel .tif UAV image to separate files according to the channel

Hello, I’ m trying to separate a UAV .tif (containing four channels: green, red, red-edge, NIR) to four different images, one for each channel. The code that I used for normal RGB (3 channel .tif) worked perfectly but I when I try to implement it to the 4-channel UAV .tif image with the related modifications in the code, I get this message…

  File "code.py", line 4, in <module>
    g,r,re,nir = cv2.split(img)
ValueError: not enough values to unpack (expected 4, got 0)

Any idea how to fix this?