Skip to content

Commit

Permalink
Fix pip_deps targets.
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 682431974
  • Loading branch information
joezoug authored and copybara-github committed Oct 4, 2024
1 parent 41a101d commit 370efbd
Show file tree
Hide file tree
Showing 24 changed files with 166 additions and 209 deletions.
4 changes: 2 additions & 2 deletions mediapipe/model_maker/python/core/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ py_library(
name = "hyperparameters",
srcs = ["hyperparameters.py"],
deps = [
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps//tensorflow_models/official/common:distribute_utils",
"@model_maker_pip_deps_tensorflow//:pkg",
"@model_maker_pip_deps_tf_models_official//:pkg",
],
)
24 changes: 12 additions & 12 deletions mediapipe/model_maker/python/core/data/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -23,9 +23,9 @@ py_library(
name = "data_util",
srcs = ["data_util.py"],
deps = [
"@model_maker_pip_deps//cv2",
"@model_maker_pip_deps//numpy",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_numpy//:pkg",
"@model_maker_pip_deps_opencv_python//:pkg",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -35,16 +35,16 @@ py_test(
data = ["//mediapipe/model_maker/python/core/data/testdata"],
deps = [
":data_util",
"@model_maker_pip_deps//absl/flags",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_absl_py//:pkg",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

py_library(
name = "dataset",
srcs = ["dataset.py"],
srcs_version = "PY3",
deps = ["@model_maker_pip_deps//tensorflow"],
deps = ["@model_maker_pip_deps_tensorflow//:pkg"],
)

py_test(
Expand All @@ -53,8 +53,8 @@ py_test(
deps = [
":dataset",
"//mediapipe/model_maker/python/core/utils:test_util",
"@model_maker_pip_deps//numpy",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_numpy//:pkg",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -63,7 +63,7 @@ py_library(
srcs = ["classification_dataset.py"],
deps = [
":dataset",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -72,21 +72,21 @@ py_test(
srcs = ["classification_dataset_test.py"],
deps = [
":classification_dataset",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

py_library(
name = "cache_files",
srcs = ["cache_files.py"],
deps = ["@model_maker_pip_deps//tensorflow"],
deps = ["@model_maker_pip_deps_tensorflow//:pkg"],
)

py_test(
name = "cache_files_test",
srcs = ["cache_files_test.py"],
deps = [
":cache_files",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)
8 changes: 4 additions & 4 deletions mediapipe/model_maker/python/core/tasks/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ py_library(
"//mediapipe/model_maker/python/core/data:dataset",
"//mediapipe/model_maker/python/core/utils:model_util",
"//mediapipe/model_maker/python/core/utils:quantization",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -36,7 +36,7 @@ py_test(
deps = [
":custom_model",
"//mediapipe/model_maker/python/core/utils:test_util",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -49,7 +49,7 @@ py_library(
"//mediapipe/model_maker/python/core/data:classification_dataset",
"//mediapipe/model_maker/python/core/data:dataset",
"//mediapipe/model_maker/python/core/utils:model_util",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -59,6 +59,6 @@ py_test(
deps = [
":classifier",
"//mediapipe/model_maker/python/core/utils:test_util",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)
44 changes: 22 additions & 22 deletions mediapipe/model_maker/python/core/utils/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ py_library(
deps = [
":model_util",
"//mediapipe/model_maker/python/core/data:dataset",
"@model_maker_pip_deps//numpy",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_numpy//:pkg",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -44,8 +44,8 @@ py_library(
deps = [
":quantization",
"//mediapipe/model_maker/python/core/data:dataset",
"@model_maker_pip_deps//numpy",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_numpy//:pkg",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -56,8 +56,8 @@ py_test(
":model_util",
":quantization",
":test_util",
"@model_maker_pip_deps//absl/testing:parameterized",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_absl_py//:pkg",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -73,15 +73,15 @@ py_test(
tags = ["requires-net:external"],
deps = [
":file_util",
"@model_maker_pip_deps//absl/testing:absltest",
"@model_maker_pip_deps_absl_py//:pkg",
],
)

py_library(
name = "hub_loader",
srcs = ["hub_loader.py"],
deps = [
"@model_maker_pip_deps//tensorflow_hub",
"@model_maker_pip_deps_tensorflow_hub//:pkg",
],
)

Expand All @@ -92,8 +92,8 @@ py_test(
deps = [
":hub_loader",
"//mediapipe/tasks/python/test:test_utils",
"@model_maker_pip_deps//absl/testing:parameterized",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_absl_py//:pkg",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -104,9 +104,9 @@ py_library(
deps = [
":file_util",
":model_util",
"@model_maker_pip_deps//numpy",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps//tensorflow_models/official/modeling:tf_utils",
"@model_maker_pip_deps_numpy//:pkg",
"@model_maker_pip_deps_tensorflow//:pkg",
"@model_maker_pip_deps_tf_models_official//:pkg",
],
)

Expand All @@ -118,8 +118,8 @@ py_test(
],
deps = [
":loss_functions",
"@model_maker_pip_deps//absl/testing:parameterized",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_absl_py//:pkg",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -135,7 +135,7 @@ py_library(
name = "metrics",
srcs = ["metrics.py"],
deps = [
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -144,9 +144,9 @@ py_test(
srcs = ["metrics_test.py"],
deps = [
":metrics",
"@model_maker_pip_deps//absl/testing:parameterized",
"@model_maker_pip_deps//numpy",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_absl_py//:pkg",
"@model_maker_pip_deps_numpy//:pkg",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -157,7 +157,7 @@ py_library(
visibility = ["//visibility:public"],
deps = [
"//mediapipe/model_maker/python/core/data:dataset",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -167,7 +167,7 @@ py_test(
deps = [
":quantization",
":test_util",
"@model_maker_pip_deps//absl/testing:parameterized",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_absl_py//:pkg",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)
50 changes: 24 additions & 26 deletions mediapipe/model_maker/python/text/text_classifier/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ py_test(
":hyperparameters",
":model_options",
":model_spec",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -88,7 +88,7 @@ py_library(
deps = [
"//mediapipe/model_maker/python/core/data:cache_files",
"//mediapipe/model_maker/python/core/data:classification_dataset",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -97,15 +97,15 @@ py_test(
srcs = ["dataset_test.py"],
deps = [
":dataset",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

py_library(
name = "model_with_tokenizer",
srcs = ["model_with_tokenizer.py"],
deps = [
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -118,18 +118,18 @@ py_test(
":model_spec",
":model_with_tokenizer",
"//mediapipe/model_maker/python/core/utils:hub_loader",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps//tensorflow_hub",
"@model_maker_pip_deps_tensorflow//:pkg",
"@model_maker_pip_deps_tensorflow_hub//:pkg",
],
)

py_library(
name = "bert_tokenizer",
srcs = ["bert_tokenizer.py"],
deps = [
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps//tensorflow_models/official/nlp/tools:tokenization",
"@model_maker_pip_deps//tensorflow_text",
"@model_maker_pip_deps_tensorflow//:pkg",
"@model_maker_pip_deps_tensorflow_text//:pkg",
"@model_maker_pip_deps_tf_models_official//:pkg",
],
)

Expand All @@ -140,9 +140,9 @@ py_test(
deps = [
":bert_tokenizer",
":model_spec",
"@model_maker_pip_deps//absl/testing:parameterized",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps//tensorflow_hub",
"@model_maker_pip_deps_absl_py//:pkg",
"@model_maker_pip_deps_tensorflow//:pkg",
"@model_maker_pip_deps_tensorflow_hub//:pkg",
],
)

Expand All @@ -153,8 +153,8 @@ py_library(
":bert_tokenizer",
":dataset",
"//mediapipe/model_maker/python/core/data:cache_files",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps//tensorflow_hub",
"@model_maker_pip_deps_tensorflow//:pkg",
"@model_maker_pip_deps_tensorflow_hub//:pkg",
],
)

Expand All @@ -168,9 +168,9 @@ py_test(
":model_spec",
":preprocessor",
"//mediapipe/model_maker/python/core/data:cache_files",
"@model_maker_pip_deps//absl/testing:parameterized",
"@model_maker_pip_deps//numpy",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_absl_py//:pkg",
"@model_maker_pip_deps_numpy//:pkg",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand Down Expand Up @@ -205,9 +205,9 @@ py_library(
"//mediapipe/model_maker/python/core/utils:quantization",
"//mediapipe/tasks/python/metadata/metadata_writers:metadata_writer",
"//mediapipe/tasks/python/metadata/metadata_writers:text_classifier",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps//tensorflow_addons",
"@model_maker_pip_deps//tensorflow_hub",
"@model_maker_pip_deps_tensorflow//:pkg",
"@model_maker_pip_deps_tensorflow_addons//:pkg",
"@model_maker_pip_deps_tensorflow_hub//:pkg",
],
)

Expand All @@ -228,8 +228,8 @@ py_test(
":text_classifier_import",
"//mediapipe/model_maker/python/core/utils:loss_functions",
"//mediapipe/tasks/python/test:test_utils",
"@model_maker_pip_deps//absl/testing:parameterized",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_absl_py//:pkg",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand All @@ -239,10 +239,8 @@ py_library(
deps = [
":text_classifier_import",
"//mediapipe/model_maker/python/core/utils:quantization",
"@model_maker_pip_deps//absl:app",
"@model_maker_pip_deps//absl/flags",
"@model_maker_pip_deps//absl/logging",
"@model_maker_pip_deps//tensorflow",
"@model_maker_pip_deps_absl_py//:pkg",
"@model_maker_pip_deps_tensorflow//:pkg",
],
)

Expand Down
Loading

0 comments on commit 370efbd

Please sign in to comment.