models
Models and examples built with TensorFlow
The TensorFlow Model Garden is a curated collection of official and research model implementations in TensorFlow, ready-to-run reference code for training state-of-the-art models on CPU, GPU, or TPU.
The TensorFlow Model Garden is a collection of model implementations and examples built with TensorFlow. Its stated goal is to demonstrate best practices so TensorFlow users can take full advantage of the framework for research and product development. It does not provide a single model, but a curated set of reference implementations contributors can read, run, modify, and use as starting points.
Inside the repository the code is split into a few directories. The official directory holds example implementations of state-of-the-art models written with TensorFlow 2's high-level APIs; these are officially maintained, kept up to date, and "reasonably optimized for fast performance while still being easy to read." The research directory contains model implementations contributed by researchers in TensorFlow 1 or 2, maintained by those researchers rather than the core team. The community directory is a curated list of GitHub repositories outside this one that hold models powered by TensorFlow 2. Finally, orbit is a flexible, lightweight library for writing customized training loops in TensorFlow 2.x — it integrates with tf.distribute and supports running on CPU, GPU, and TPU.
Two installation paths are described. The first is a pip package, tf-models-official, that installs all models and their dependencies; a tf-models-nightly package tracks the master branch. The second is cloning the repository and adding it to the Python path.
Someone would use the Model Garden when they want a known-good TensorFlow implementation of a published model to study, fine-tune, or build a product on top of, instead of writing one from scratch. The code is in Python and licensed under Apache-2.0.
Where it fits
- Fine-tune an official TensorFlow model on your own dataset without writing training code from scratch.
- Use a research directory implementation as a verified starting point for reproducing a published paper's results.
- Install the tf-models-official pip package to get an optimized, maintained model implementation with GPU and TPU support.
- Use the orbit library to write a custom TensorFlow 2 training loop that integrates with tf.distribute for multi-device training.