This is in no way NumPy-specific, but is consistent with how Python treats NaNs:
In [1]: bool(float('nan'))
Out[1]: True
The rules are spelled out in the documentation.
I think it could be reasonably argued that the truth value of NaN should be False. However, this is not how the language works right now.
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…