Hi, am having the same problem… and my target has 3 classes, 0 and 1 and 255 which is the ignore index. I defined my weights as [0.1,0.9] for 0 and 1, but it didnt work… I suppose it s because of the ignore index 255, but isnt it gonna be ignored anyhow?
How I can work around this? Thanks