Home | History | Annotate | Download | only in image_retraining
      1 # Description:
      2 # Transfer learning example for TensorFlow.
      3 
      4 licenses(["notice"])  # Apache 2.0
      5 
      6 exports_files(["LICENSE"])
      7 
      8 load("//tensorflow:tensorflow.bzl", "py_test")
      9 
     10 py_binary(
     11     name = "retrain",
     12     srcs = [
     13         "retrain.py",
     14     ],
     15     srcs_version = "PY2AND3",
     16     visibility = ["//tensorflow:__subpackages__"],
     17     deps = [
     18         "//tensorflow:tensorflow_py",
     19         "//tensorflow/python:framework",
     20         "//tensorflow/python:framework_for_generated_wrappers",
     21         "//tensorflow/python:graph_util",
     22         "//tensorflow/python:platform",
     23         "//tensorflow/python:util",
     24         "//third_party/py/numpy",
     25     ],
     26 )
     27 
     28 py_test(
     29     name = "retrain_test",
     30     size = "small",
     31     srcs = [
     32         "retrain.py",
     33         "retrain_test.py",
     34     ],
     35     data = [
     36         ":data/labels.txt",
     37         "//tensorflow/examples/label_image:data/grace_hopper.jpg",
     38     ],
     39     srcs_version = "PY2AND3",
     40     deps = [
     41         ":retrain",
     42         "//tensorflow:tensorflow_py",
     43         "//tensorflow/python:framework_test_lib",
     44         "//tensorflow/python:graph_util",
     45         "//tensorflow/python:platform",
     46         "//tensorflow/python:platform_test",
     47         "//tensorflow/python:tensor_shape",
     48         "//tensorflow/python:util",
     49         "//third_party/py/numpy",
     50     ],
     51 )
     52 
     53 filegroup(
     54     name = "all_files",
     55     srcs = glob(
     56         ["**/*"],
     57         exclude = [
     58             "**/METADATA",
     59             "**/OWNERS",
     60         ],
     61     ),
     62     visibility = ["//tensorflow:__subpackages__"],
     63 )
     64