def _get_model(spec, compute_units=_ComputeUnit.ALL):
    """
    Utility to get the model and the data.
    """
    if isinstance(spec, _ct.models.MLModel):
        return spec
    else:
        return _ct.models.MLModel(spec, compute_units=compute_units)

    Utility to get the model and the data.
    
coremltools/models/utils.py