def METHOD_NAME(weight):
    """ Return the weight property as a numeric value.
    String values are converted to their corresponding numeric value.
    """
    if isinstance(weight, str):
        try:
            weight = weight_dict[weight.lower()]
        except KeyError:
            weight = weight_dict["regular"]
    elif 100 <= weight <= 1000:
        pass
    else:
        raise ValueError("weight not a valid integer")
    return weight