def get_grasp(parts, g_w):
    """
    Get the best region for grasping. With no part is viable, return -2.

    Parameters:
    -----------
        parts: ObjParts array N
        g_w: float
    Returns:
    -----------
        indice: int
    """
    for i in range(len(parts)):
        if(parts[i].largura < g_w and parts[i].curvatura > 0.016):
            return i
    return -2