π Geometric Computer Vision Library for Spatial AI
Python artificial-intelligencecomputer-visiondeep-learninghacktoberfestimage-processingmachine-learningneural-networkpythonpytorchroboticsspatial-ai
dice_loss and DiceLoss raise TypeCheckError, a TypeError, when target is not a tensor; it used to be an AttributeError, or a misleading device-mismatch ValueError for a NumPy array. They raise ValueError when eps is a negative Python int or float (DiceLoss at construction); such an eps used to be accepted: eps=-1e-8 gave the eps=0 loss, and eps=-inf gave 1. A tensor eps, including one per class, is not checked and works as before. DiceLoss also rejects an unknown average when it is created instead of at its first call.