def save_model(model, path="", force=False):
    """
    Save an H2O Model object to disk. (Note that ensemble binary models can now be saved using this method.)

    :param model: The model object to save.
    :param path: a path to save the model at (hdfs, s3, local)
    :param force: if True overwrite destination directory in case it exists, or throw exception if set to False.

    :returns: the path of the saved model

    :examples:
        >>> path = h2o.save_model(my_model, dir=my_path)
    """
    assert_is_type(model, ModelBase)
    assert_is_type(path, str)
    assert_is_type(force, bool)
    path = os.path.join(os.getcwd() if path == "" else path, model.model_id)
    return api("GET /99/Models.bin/%s" % model.model_id, data={"dir": path, "force": force})["dir"]