i’m not sure but i think it may have something to do with how the rpn box loss calculated.  again, i’m not     sure and this is only a guess. Perhaps as x1 is smaller than x2, a negative loss is calculated and that is what is causing the NaN value. I am still looking into how the rpn box loss is being calculated based on the rpn.py file.