From f3ae36761880f8ae73141144a747c688513ee6af Mon Sep 17 00:00:00 2001 From: "A. Unique TensorFlower" Date: Fri, 18 May 2018 18:18:21 -0700 Subject: [PATCH] Delete unused and buggy code. (Note the mistaken argument order of the string constructors.) PiperOrigin-RevId: 197229855 --- .../core/util/example_proto_fast_parsing_test.cc | 30 +--------------------- 1 file changed, 1 insertion(+), 29 deletions(-) diff --git a/tensorflow/core/util/example_proto_fast_parsing_test.cc b/tensorflow/core/util/example_proto_fast_parsing_test.cc index 13e41c1..1a804e1 100644 --- a/tensorflow/core/util/example_proto_fast_parsing_test.cc +++ b/tensorflow/core/util/example_proto_fast_parsing_test.cc @@ -12,6 +12,7 @@ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License. ==============================================================================*/ + #include "tensorflow/core/util/example_proto_fast_parsing.h" #include "tensorflow/core/example/example.pb.h" @@ -336,34 +337,6 @@ TEST(FastParse, FuzzTest) { } } -string MakeSerializedExample() { - Example example; - const int kFeatureNameLength = 10; - const int kFeatureValueLength = 20; - const int kBytesFeatureCount = 200; - const int kFloatFeatureCount = 200; - const int kInt64FeatureCount = 200; - auto& fmap = *example.mutable_features()->mutable_feature(); - for (int i = 0; i < kBytesFeatureCount; ++i) { - fmap[strings::StrCat(string('b', kFeatureNameLength), i)] - .mutable_bytes_list() - ->add_value(string('v', kFeatureValueLength)); - } - for (int i = 0; i < kFloatFeatureCount; ++i) { - fmap[strings::StrCat(string('f', kFeatureNameLength), i)] - .mutable_float_list() - ->add_value(123123123.123); - } - for (int i = 0; i < kInt64FeatureCount; ++i) { - fmap[strings::StrCat(string('i', kFeatureNameLength), i)] - .mutable_int64_list() - ->add_value(10 * i); - } - string serialized; - example.SerializeToString(&serialized); - return serialized; -} - TEST(TestFastParseExample, Empty) { Result result; FastParseExampleConfig config; @@ -374,6 +347,5 @@ TEST(TestFastParseExample, Empty) { } } // namespace - } // namespace example } // namespace tensorflow -- 2.7.4