View source on GitHub

Loads a ModuleSpec from the filesystem.

DEPRECATION NOTE: This belongs to the hub.Module API and file format for TF1. For TF2, switch to plain SavedModels and hub.load().

path string describing the location of a module. There are several supported path encoding schemes: a) URL location specifying an archived module (e.g. http://domain/module.tgz) b) Any filesystem location of a module directory (e.g. /module_dir for a local filesystem). All filesystems implementations provided by Tensorflow are supported.

A ModuleSpec.

ValueError on unexpected values in the module spec.
tf.errors.OpError on file handling exceptions.