tensorflow/models

View on GitHub
research/object_detection/core/batch_multiclass_nms_test.py

Summary

Maintainability
F
1 mo
Test Coverage

File batch_multiclass_nms_test.py has 624 lines of code (exceeds 250 allowed). Consider refactoring.
Open

# Copyright 2019 The TensorFlow Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
Severity: Major
Found in research/object_detection/core/batch_multiclass_nms_test.py - About 1 day to fix

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

        masks = np.array([[[[[0, 1], [2, 3]], [[1, 2], [3, 4]]],
                           [[[2, 3], [4, 5]], [[3, 4], [5, 6]]],
                           [[[4, 5], [6, 7]], [[5, 6], [7, 8]]],
                           [[[6, 7], [8, 9]], [[7, 8], [9, 10]]]],
                          [[[[8, 9], [10, 11]], [[9, 10], [11, 12]]],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 1 other location - About 1 day to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 439..447

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 195.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

        masks = np.array([[[[[0, 1], [2, 3]], [[1, 2], [3, 4]]],
                           [[[2, 3], [4, 5]], [[3, 4], [5, 6]]],
                           [[[4, 5], [6, 7]], [[5, 6], [7, 8]]],
                           [[[6, 7], [8, 9]], [[7, 8], [9, 10]]]],
                          [[[[8, 9], [10, 11]], [[9, 10], [11, 12]]],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 1 other location - About 1 day to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 272..280

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 195.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

        def graph_fn(boxes, scores, clip_window):
          (nmsed_boxes, nmsed_scores, nmsed_classes, nmsed_masks,
           nmsed_additional_fields, num_detections
          ) = post_processing.batch_multiclass_non_max_suppression(
              boxes, scores, score_thresh, iou_thresh,
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 1 other location - About 1 day to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 232..249

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 137.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

        def graph_fn(boxes, scores, clip_window):
          (nmsed_boxes, nmsed_scores, nmsed_classes, nmsed_masks,
           nmsed_additional_fields, num_detections
          ) = post_processing.batch_multiclass_non_max_suppression(
              boxes, scores, score_thresh, iou_thresh,
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 1 other location - About 1 day to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 173..190

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 137.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        boxes = np.array([[[[0, 0, 1, 1], [0, 0, 4, 5]],
                           [[0, 0.1, 1, 1.1], [0, 0.1, 2, 1.1]],
                           [[0, -0.1, 1, 0.9], [0, -0.1, 1, 0.9]],
                           [[0, 10, 1, 11], [0, 10, 1, 11]]],
                          [[[0, 10.1, 1, 11.1], [0, 10.1, 1, 11.1]],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 1 day to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 86..94
    research/object_detection/core/batch_multiclass_nms_test.py on lines 200..208
    research/object_detection/core/batch_multiclass_nms_test.py on lines 259..267
    research/object_detection/core/batch_multiclass_nms_test.py on lines 332..340
    research/object_detection/core/batch_multiclass_nms_test.py on lines 426..434
    research/object_detection/core/batch_multiclass_nms_test.py on lines 496..504
    research/object_detection/core/batch_multiclass_nms_test.py on lines 584..592
    research/object_detection/core/batch_multiclass_nms_test.py on lines 632..640

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 131.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        boxes = np.array([[[[0, 0, 1, 1], [0, 0, 4, 5]],
                           [[0, 0.1, 1, 1.1], [0, 0.1, 2, 1.1]],
                           [[0, -0.1, 1, 0.9], [0, -0.1, 1, 0.9]],
                           [[0, 10, 1, 11], [0, 10, 1, 11]]],
                          [[[0, 10.1, 1, 11.1], [0, 10.1, 1, 11.1]],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 1 day to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 86..94
    research/object_detection/core/batch_multiclass_nms_test.py on lines 143..151
    research/object_detection/core/batch_multiclass_nms_test.py on lines 200..208
    research/object_detection/core/batch_multiclass_nms_test.py on lines 332..340
    research/object_detection/core/batch_multiclass_nms_test.py on lines 426..434
    research/object_detection/core/batch_multiclass_nms_test.py on lines 496..504
    research/object_detection/core/batch_multiclass_nms_test.py on lines 584..592
    research/object_detection/core/batch_multiclass_nms_test.py on lines 632..640

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 131.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        boxes = np.array([[[[0, 0, 0.1, 0.1], [0, 0, 0.1, 0.1]],
                           [[0, 0.01, 1, 0.11], [0, 0.6, 0.1, 0.7]],
                           [[0, -0.01, 0.1, 0.09], [0, -0.1, 0.1, 0.09]],
                           [[0, 0.11, 0.1, 0.2], [0, 0.11, 0.1, 0.2]]],
                          [[[0, 0, 0.2, 0.2], [0, 0, 0.2, 0.2]],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 1 day to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 86..94
    research/object_detection/core/batch_multiclass_nms_test.py on lines 143..151
    research/object_detection/core/batch_multiclass_nms_test.py on lines 200..208
    research/object_detection/core/batch_multiclass_nms_test.py on lines 259..267
    research/object_detection/core/batch_multiclass_nms_test.py on lines 332..340
    research/object_detection/core/batch_multiclass_nms_test.py on lines 426..434
    research/object_detection/core/batch_multiclass_nms_test.py on lines 496..504
    research/object_detection/core/batch_multiclass_nms_test.py on lines 632..640

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 131.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        boxes = np.array([[[[0, 0, 1, 1], [0, 0, 4, 5]],
                           [[0, 0.1, 1, 1.1], [0, 0.1, 2, 1.1]],
                           [[0, -0.1, 1, 0.9], [0, -0.1, 1, 0.9]],
                           [[0, 10, 1, 11], [0, 10, 1, 11]]],
                          [[[0, 10.1, 1, 11.1], [0, 10.1, 1, 11.1]],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 1 day to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 86..94
    research/object_detection/core/batch_multiclass_nms_test.py on lines 143..151
    research/object_detection/core/batch_multiclass_nms_test.py on lines 200..208
    research/object_detection/core/batch_multiclass_nms_test.py on lines 259..267
    research/object_detection/core/batch_multiclass_nms_test.py on lines 332..340
    research/object_detection/core/batch_multiclass_nms_test.py on lines 426..434
    research/object_detection/core/batch_multiclass_nms_test.py on lines 584..592
    research/object_detection/core/batch_multiclass_nms_test.py on lines 632..640

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 131.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        boxes = np.array([[[[0, 0, 1, 1], [0, 0, 4, 5]],
                           [[0, 0.1, 1, 1.1], [0, 0.1, 2, 1.1]],
                           [[0, -0.1, 1, 0.9], [0, -0.1, 1, 0.9]],
                           [[0, 10, 1, 11], [0, 10, 1, 11]]],
                          [[[0, 10.1, 1, 11.1], [0, 10.1, 1, 11.1]],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 1 day to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 86..94
    research/object_detection/core/batch_multiclass_nms_test.py on lines 143..151
    research/object_detection/core/batch_multiclass_nms_test.py on lines 200..208
    research/object_detection/core/batch_multiclass_nms_test.py on lines 259..267
    research/object_detection/core/batch_multiclass_nms_test.py on lines 426..434
    research/object_detection/core/batch_multiclass_nms_test.py on lines 496..504
    research/object_detection/core/batch_multiclass_nms_test.py on lines 584..592
    research/object_detection/core/batch_multiclass_nms_test.py on lines 632..640

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 131.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        boxes = np.array([[[[0, 0, 1, 1], [0, 0, 4, 5]],
                           [[0, 0.1, 1, 1.1], [0, 0.1, 2, 1.1]],
                           [[0, -0.1, 1, 0.9], [0, -0.1, 1, 0.9]],
                           [[0, 10, 1, 11], [0, 10, 1, 11]]],
                          [[[0, 10.1, 1, 11.1], [0, 10.1, 1, 11.1]],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 1 day to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 86..94
    research/object_detection/core/batch_multiclass_nms_test.py on lines 143..151
    research/object_detection/core/batch_multiclass_nms_test.py on lines 259..267
    research/object_detection/core/batch_multiclass_nms_test.py on lines 332..340
    research/object_detection/core/batch_multiclass_nms_test.py on lines 426..434
    research/object_detection/core/batch_multiclass_nms_test.py on lines 496..504
    research/object_detection/core/batch_multiclass_nms_test.py on lines 584..592
    research/object_detection/core/batch_multiclass_nms_test.py on lines 632..640

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 131.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        boxes = np.array([[[[0, 0, 1, 1], [0, 0, 4, 5]],
                           [[0, 0.1, 1, 1.1], [0, 0.1, 2, 1.1]],
                           [[0, -0.1, 1, 0.9], [0, -0.1, 1, 0.9]],
                           [[0, 10, 1, 11], [0, 10, 1, 11]]],
                          [[[0, 10.1, 1, 11.1], [0, 10.1, 1, 11.1]],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 1 day to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 143..151
    research/object_detection/core/batch_multiclass_nms_test.py on lines 200..208
    research/object_detection/core/batch_multiclass_nms_test.py on lines 259..267
    research/object_detection/core/batch_multiclass_nms_test.py on lines 332..340
    research/object_detection/core/batch_multiclass_nms_test.py on lines 426..434
    research/object_detection/core/batch_multiclass_nms_test.py on lines 496..504
    research/object_detection/core/batch_multiclass_nms_test.py on lines 584..592
    research/object_detection/core/batch_multiclass_nms_test.py on lines 632..640

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 131.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        boxes = np.array([[[[0, 0, 1, 1], [0, 0, 4, 5]],
                           [[0, 0.1, 1, 1.1], [0, 0.1, 2, 1.1]],
                           [[0, -0.1, 1, 0.9], [0, -0.1, 1, 0.9]],
                           [[0, 10, 1, 11], [0, 10, 1, 11]]],
                          [[[0, 10.1, 1, 11.1], [0, 10.1, 1, 11.1]],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 1 day to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 86..94
    research/object_detection/core/batch_multiclass_nms_test.py on lines 143..151
    research/object_detection/core/batch_multiclass_nms_test.py on lines 200..208
    research/object_detection/core/batch_multiclass_nms_test.py on lines 259..267
    research/object_detection/core/batch_multiclass_nms_test.py on lines 332..340
    research/object_detection/core/batch_multiclass_nms_test.py on lines 496..504
    research/object_detection/core/batch_multiclass_nms_test.py on lines 584..592
    research/object_detection/core/batch_multiclass_nms_test.py on lines 632..640

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 131.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        boxes = np.array([[[[0, 0, 1, 1], [0, 0, 4, 5]],
                           [[0, 0.1, 1, 1.1], [0, 0.1, 2, 1.1]],
                           [[0, -0.1, 1, 0.9], [0, -0.1, 1, 0.9]],
                           [[0, 10, 1, 11], [0, 10, 1, 11]]],
                          [[[0, 10.1, 1, 11.1], [0, 10.1, 1, 11.1]],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 1 day to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 86..94
    research/object_detection/core/batch_multiclass_nms_test.py on lines 143..151
    research/object_detection/core/batch_multiclass_nms_test.py on lines 200..208
    research/object_detection/core/batch_multiclass_nms_test.py on lines 259..267
    research/object_detection/core/batch_multiclass_nms_test.py on lines 332..340
    research/object_detection/core/batch_multiclass_nms_test.py on lines 426..434
    research/object_detection/core/batch_multiclass_nms_test.py on lines 496..504
    research/object_detection/core/batch_multiclass_nms_test.py on lines 584..592

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 131.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

        exp_nms_additional_fields = {
            'keypoints': np.array([[[[6, 7], [8, 9]],
                                    [[0, 0], [0, 0]],
                                    [[0, 0], [0, 0]],
                                    [[0, 0], [0, 0]]],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 1 other location - About 6 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 374..382

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 100.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

        exp_nms_additional_fields = {
            'keypoints': np.array([[[[0, 0], [0, 0]],
                                    [[6, 7], [8, 9]],
                                    [[0, 0], [0, 0]],
                                    [[0, 0], [0, 0]]],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 1 other location - About 6 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 540..548

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 100.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

        keypoints = np.array(
            [[[[6, 7], [8, 9]],
              [[0, 1], [2, 3]],
              [[0, 0], [0, 0]],
              [[0, 0], [0, 0]]],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 1 other location - About 6 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 345..354

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 99.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

        keypoints = np.array(
            [[[[6, 7], [8, 9]],
              [[0, 1], [2, 3]],
              [[0, 0], [0, 0]],
              [[0, 0], [0, 0]]],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 1 other location - About 6 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 509..518

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 99.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

        exp_nms_additional_fields['size'] = np.array([[[[7], [9]], [[0], [0]],
                                                       [[0], [0]], [[0], [0]]],
                                                      [[[14], [16]], [[0], [0]],
                                                       [[0], [0]], [[0], [0]]]])
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 1 other location - About 5 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 384..387

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 86.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

        exp_nms_additional_fields['size'] = np.array([[[[0], [0]], [[6], [8]],
                                                       [[0], [0]], [[0], [0]]],
                                                      [[[10], [12]], [[13], [15]],
                                                       [[8], [10]], [[0], [0]]]])
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 1 other location - About 5 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 551..554

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 86.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

        size = np.array(
            [[[[7], [9]], [[1], [3]], [[0], [0]], [[0], [0]]],
             [[[14], [16]], [[9], [11]], [[11], [13]], [[0], [0]]]], np.float32)
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 1 other location - About 4 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 355..357

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 83.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

        size = np.array(
            [[[[6], [8]], [[0], [2]], [[0], [0]], [[0], [0]]],
             [[[13], [15]], [[8], [10]], [[10], [12]], [[0], [0]]]], np.float32)
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 1 other location - About 4 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 519..521

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 83.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        exp_nms_corners = np.array([[[0, 10, 1, 11],
                                     [0, 0, 1, 1],
                                     [0, 0, 0, 0],
                                     [0, 0, 0, 0]],
                                    [[0, 999, 2, 1004],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 5 other locations - About 3 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 161..168
    research/object_detection/core/batch_multiclass_nms_test.py on lines 219..226
    research/object_detection/core/batch_multiclass_nms_test.py on lines 285..292
    research/object_detection/core/batch_multiclass_nms_test.py on lines 362..369
    research/object_detection/core/batch_multiclass_nms_test.py on lines 653..660

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 64.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        exp_nms_corners = np.array([[[0, 10, 1, 11],
                                     [0, 0, 1, 1],
                                     [0, 0, 0, 0],
                                     [0, 0, 0, 0]],
                                    [[0, 999, 2, 1004],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 5 other locations - About 3 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 103..110
    research/object_detection/core/batch_multiclass_nms_test.py on lines 161..168
    research/object_detection/core/batch_multiclass_nms_test.py on lines 219..226
    research/object_detection/core/batch_multiclass_nms_test.py on lines 285..292
    research/object_detection/core/batch_multiclass_nms_test.py on lines 653..660

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 64.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        exp_nms_corners = np.array([[[0, 10, 1, 11],
                                     [0, 0, 1, 1],
                                     [0, 0, 0, 0],
                                     [0, 0, 0, 0]],
                                    [[0, 999, 2, 1004],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 5 other locations - About 3 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 103..110
    research/object_detection/core/batch_multiclass_nms_test.py on lines 161..168
    research/object_detection/core/batch_multiclass_nms_test.py on lines 219..226
    research/object_detection/core/batch_multiclass_nms_test.py on lines 362..369
    research/object_detection/core/batch_multiclass_nms_test.py on lines 653..660

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 64.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        exp_nms_corners = np.array([[[0, 0, 1, 1],
                                     [0, 0, 0, 0],
                                     [0, 0, 0, 0],
                                     [0, 0, 0, 0]],
                                    [[0, 10.1, 1, 11.1],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 5 other locations - About 3 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 103..110
    research/object_detection/core/batch_multiclass_nms_test.py on lines 161..168
    research/object_detection/core/batch_multiclass_nms_test.py on lines 285..292
    research/object_detection/core/batch_multiclass_nms_test.py on lines 362..369
    research/object_detection/core/batch_multiclass_nms_test.py on lines 653..660

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 64.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        exp_nms_corners = np.array([[[0, 10, 1, 11],
                                     [0, 0, 1, 1],
                                     [0, 0, 0, 0],
                                     [0, 0, 0, 0]],
                                    [[0, 10.1, 1, 11.1],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 5 other locations - About 3 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 103..110
    research/object_detection/core/batch_multiclass_nms_test.py on lines 219..226
    research/object_detection/core/batch_multiclass_nms_test.py on lines 285..292
    research/object_detection/core/batch_multiclass_nms_test.py on lines 362..369
    research/object_detection/core/batch_multiclass_nms_test.py on lines 653..660

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 64.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 6 locations. Consider refactoring.
    Open

        exp_nms_corners = np.array([[[0, 0, 1, 1],
                                     [0, 0, 0, 0],
                                     [0, 0, 0, 0],
                                     [0, 0, 0, 0]],
                                    [[0, 10.1, 1, 11.1],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 5 other locations - About 3 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 103..110
    research/object_detection/core/batch_multiclass_nms_test.py on lines 161..168
    research/object_detection/core/batch_multiclass_nms_test.py on lines 219..226
    research/object_detection/core/batch_multiclass_nms_test.py on lines 285..292
    research/object_detection/core/batch_multiclass_nms_test.py on lines 362..369

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 64.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

        exp_nms_corners = [[[0, 0, 1, 1],
                            [0, 0, 0, 0],
                            [0, 0, 0, 0],
                            [0, 0, 0, 0]],
                           [[0, 10.1, 1, 11.1],
    official/vision/dataloaders/tf_example_decoder_test.py on lines 103..110
    official/vision/dataloaders/tf_example_decoder_test.py on lines 225..232
    official/vision/dataloaders/tf_example_label_map_decoder_test.py on lines 106..113
    research/object_detection/core/batch_multiclass_nms_test.py on lines 528..535
    research/object_detection/core/target_assigner_test.py on lines 534..541
    research/object_detection/core/target_assigner_test.py on lines 583..590
    research/object_detection/core/target_assigner_test.py on lines 591..598
    research/object_detection/core/target_assigner_test.py on lines 599..606
    research/object_detection/core/target_assigner_test.py on lines 658..665
    research/object_detection/core/target_assigner_test.py on lines 666..673
    research/object_detection/core/target_assigner_test.py on lines 674..681
    research/object_detection/core/target_assigner_test.py on lines 763..770
    research/object_detection/core/target_assigner_test.py on lines 970..977
    research/object_detection/core/target_assigner_test.py on lines 1025..1032
    research/object_detection/core/target_assigner_test.py on lines 1033..1040
    research/object_detection/core/target_assigner_test.py on lines 1041..1048
    research/object_detection/core/target_assigner_test.py on lines 1107..1114
    research/object_detection/core/target_assigner_test.py on lines 1115..1122
    research/object_detection/core/target_assigner_test.py on lines 1123..1130
    research/object_detection/meta_architectures/faster_rcnn_meta_arch_test_lib.py on lines 1069..1072
    research/object_detection/meta_architectures/faster_rcnn_meta_arch_test_lib.py on lines 1159..1162
    research/object_detection/meta_architectures/ssd_meta_arch_test.py on lines 251..254
    research/object_detection/meta_architectures/ssd_meta_arch_test.py on lines 290..301

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 58.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 24 locations. Consider refactoring.
    Open

        exp_nms_corners = [[[0, 0, 1, 1],
                            [0, 0, 0, 0],
                            [0, 0, 0, 0],
                            [0, 0, 0, 0]],
                           [[0, 10.1, 1, 11.1],
    official/vision/dataloaders/tf_example_decoder_test.py on lines 103..110
    official/vision/dataloaders/tf_example_decoder_test.py on lines 225..232
    official/vision/dataloaders/tf_example_label_map_decoder_test.py on lines 106..113
    research/object_detection/core/batch_multiclass_nms_test.py on lines 453..460
    research/object_detection/core/target_assigner_test.py on lines 534..541
    research/object_detection/core/target_assigner_test.py on lines 583..590
    research/object_detection/core/target_assigner_test.py on lines 591..598
    research/object_detection/core/target_assigner_test.py on lines 599..606
    research/object_detection/core/target_assigner_test.py on lines 658..665
    research/object_detection/core/target_assigner_test.py on lines 666..673
    research/object_detection/core/target_assigner_test.py on lines 674..681
    research/object_detection/core/target_assigner_test.py on lines 763..770
    research/object_detection/core/target_assigner_test.py on lines 970..977
    research/object_detection/core/target_assigner_test.py on lines 1025..1032
    research/object_detection/core/target_assigner_test.py on lines 1033..1040
    research/object_detection/core/target_assigner_test.py on lines 1041..1048
    research/object_detection/core/target_assigner_test.py on lines 1107..1114
    research/object_detection/core/target_assigner_test.py on lines 1115..1122
    research/object_detection/core/target_assigner_test.py on lines 1123..1130
    research/object_detection/meta_architectures/faster_rcnn_meta_arch_test_lib.py on lines 1069..1072
    research/object_detection/meta_architectures/faster_rcnn_meta_arch_test_lib.py on lines 1159..1162
    research/object_detection/meta_architectures/ssd_meta_arch_test.py on lines 251..254
    research/object_detection/meta_architectures/ssd_meta_arch_test.py on lines 290..301

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 58.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 2 locations. Consider refactoring.
    Open

        exp_nms_corners = np.array([[[0, 0.11, 0.1, 0.2],
                                     [0, 0, 0.1, 0.1],
                                     [0, 0.6, 0.1, 0.7]],
                                    [[0, 0.21, 0.2, 0.3],
                                     [0, 0, 0.2, 0.2],
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 1 other location - About 2 hrs to fix
    research/object_detection/utils/visualization_utils_test.py on lines 220..225

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 52.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        scores = np.array([[[.9, 0.01], [.75, 0.05],
                            [.6, 0.01], [.95, 0]],
                           [[.5, 0.01], [.3, 0.01],
                            [.01, .85], [.01, .5]]], np.float32)
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 2 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 95..98
    research/object_detection/core/batch_multiclass_nms_test.py on lines 209..212
    research/object_detection/core/batch_multiclass_nms_test.py on lines 268..271
    research/object_detection/core/batch_multiclass_nms_test.py on lines 341..344
    research/object_detection/core/batch_multiclass_nms_test.py on lines 435..438
    research/object_detection/core/batch_multiclass_nms_test.py on lines 505..508
    research/object_detection/core/batch_multiclass_nms_test.py on lines 593..596
    research/object_detection/core/batch_multiclass_nms_test.py on lines 641..645

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 51.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        scores = np.array([[[.9, 0.01], [.75, 0.05],
                            [.6, 0.01], [.95, 0]],
                           [[.5, 0.01], [.3, 0.01],
                            [.01, .85], [.01, .5]]], np.float32)
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 2 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 95..98
    research/object_detection/core/batch_multiclass_nms_test.py on lines 152..155
    research/object_detection/core/batch_multiclass_nms_test.py on lines 209..212
    research/object_detection/core/batch_multiclass_nms_test.py on lines 268..271
    research/object_detection/core/batch_multiclass_nms_test.py on lines 435..438
    research/object_detection/core/batch_multiclass_nms_test.py on lines 505..508
    research/object_detection/core/batch_multiclass_nms_test.py on lines 593..596
    research/object_detection/core/batch_multiclass_nms_test.py on lines 641..645

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 51.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        scores = np.array([[[.1, 0.9], [.75, 0.8],
                            [.6, 0.3], [0.95, 0.1]],
                           [[.1, 0.9], [.75, 0.8],
                            [.6, .3], [.95, .1]]], np.float32)
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 2 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 95..98
    research/object_detection/core/batch_multiclass_nms_test.py on lines 152..155
    research/object_detection/core/batch_multiclass_nms_test.py on lines 209..212
    research/object_detection/core/batch_multiclass_nms_test.py on lines 268..271
    research/object_detection/core/batch_multiclass_nms_test.py on lines 341..344
    research/object_detection/core/batch_multiclass_nms_test.py on lines 435..438
    research/object_detection/core/batch_multiclass_nms_test.py on lines 505..508
    research/object_detection/core/batch_multiclass_nms_test.py on lines 641..645

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 51.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        scores = np.array([[[.9, 0.01], [.75, 0.05],
                            [.6, 0.01], [.95, 0]],
                           [[.5, 0.01], [.3, 0.01],
                            [.01, .85], [.01, .5]]], np.float32)
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 2 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 95..98
    research/object_detection/core/batch_multiclass_nms_test.py on lines 152..155
    research/object_detection/core/batch_multiclass_nms_test.py on lines 209..212
    research/object_detection/core/batch_multiclass_nms_test.py on lines 268..271
    research/object_detection/core/batch_multiclass_nms_test.py on lines 341..344
    research/object_detection/core/batch_multiclass_nms_test.py on lines 505..508
    research/object_detection/core/batch_multiclass_nms_test.py on lines 593..596
    research/object_detection/core/batch_multiclass_nms_test.py on lines 641..645

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 51.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        scores = np.array([[[.9, 0.01], [.75, 0.05],
                            [.6, 0.01], [.95, 0]],
                           [[.5, 0.01], [.3, 0.01],
                            [.01, .85], [.01, .5]]], np.float32)
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 2 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 152..155
    research/object_detection/core/batch_multiclass_nms_test.py on lines 209..212
    research/object_detection/core/batch_multiclass_nms_test.py on lines 268..271
    research/object_detection/core/batch_multiclass_nms_test.py on lines 341..344
    research/object_detection/core/batch_multiclass_nms_test.py on lines 435..438
    research/object_detection/core/batch_multiclass_nms_test.py on lines 505..508
    research/object_detection/core/batch_multiclass_nms_test.py on lines 593..596
    research/object_detection/core/batch_multiclass_nms_test.py on lines 641..645

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 51.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        scores = np.array([[[.9, 0.01], [.75, 0.05],
                            [.6, 0.01], [.95, 0]],
                           [[.5, 0.01], [.3, 0.01],
                            [.01, .85], [.01, .5]]],
                          np.float32)
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 2 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 95..98
    research/object_detection/core/batch_multiclass_nms_test.py on lines 152..155
    research/object_detection/core/batch_multiclass_nms_test.py on lines 209..212
    research/object_detection/core/batch_multiclass_nms_test.py on lines 268..271
    research/object_detection/core/batch_multiclass_nms_test.py on lines 341..344
    research/object_detection/core/batch_multiclass_nms_test.py on lines 435..438
    research/object_detection/core/batch_multiclass_nms_test.py on lines 505..508
    research/object_detection/core/batch_multiclass_nms_test.py on lines 593..596

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 51.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        scores = np.array([[[.9, 0.01], [.75, 0.05],
                            [.6, 0.01], [.95, 0]],
                           [[.5, 0.01], [.3, 0.01],
                            [.01, .85], [.01, .5]]], np.float32)
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 2 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 95..98
    research/object_detection/core/batch_multiclass_nms_test.py on lines 152..155
    research/object_detection/core/batch_multiclass_nms_test.py on lines 209..212
    research/object_detection/core/batch_multiclass_nms_test.py on lines 268..271
    research/object_detection/core/batch_multiclass_nms_test.py on lines 341..344
    research/object_detection/core/batch_multiclass_nms_test.py on lines 435..438
    research/object_detection/core/batch_multiclass_nms_test.py on lines 593..596
    research/object_detection/core/batch_multiclass_nms_test.py on lines 641..645

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 51.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        scores = np.array([[[.9, 0.01], [.75, 0.05],
                            [.6, 0.01], [.95, 0]],
                           [[.5, 0.01], [.3, 0.01],
                            [.01, .85], [.01, .5]]], np.float32)
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 2 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 95..98
    research/object_detection/core/batch_multiclass_nms_test.py on lines 152..155
    research/object_detection/core/batch_multiclass_nms_test.py on lines 268..271
    research/object_detection/core/batch_multiclass_nms_test.py on lines 341..344
    research/object_detection/core/batch_multiclass_nms_test.py on lines 435..438
    research/object_detection/core/batch_multiclass_nms_test.py on lines 505..508
    research/object_detection/core/batch_multiclass_nms_test.py on lines 593..596
    research/object_detection/core/batch_multiclass_nms_test.py on lines 641..645

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 51.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 9 locations. Consider refactoring.
    Open

        scores = np.array([[[.9, 0.01], [.75, 0.05],
                            [.6, 0.01], [.95, 0]],
                           [[.5, 0.01], [.3, 0.01],
                            [.01, .85], [.01, .5]]], np.float32)
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 8 other locations - About 2 hrs to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 95..98
    research/object_detection/core/batch_multiclass_nms_test.py on lines 152..155
    research/object_detection/core/batch_multiclass_nms_test.py on lines 209..212
    research/object_detection/core/batch_multiclass_nms_test.py on lines 341..344
    research/object_detection/core/batch_multiclass_nms_test.py on lines 435..438
    research/object_detection/core/batch_multiclass_nms_test.py on lines 505..508
    research/object_detection/core/batch_multiclass_nms_test.py on lines 593..596
    research/object_detection/core/batch_multiclass_nms_test.py on lines 641..645

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 51.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

          self.assertAllClose(nmsed_classes[i, 0:num_detections[i]],
                              exp_nms_classes[i, 0:num_detections[i]])
    research/object_detection/core/batch_multiclass_nms_test.py on lines 677..678
    research/object_detection/core/batch_multiclass_nms_test.py on lines 679..680

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 48.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

          self.assertAllClose(nmsed_boxes[i, 0:num_detections[i]],
                              exp_nms_corners[i, 0:num_detections[i]])
    research/object_detection/core/batch_multiclass_nms_test.py on lines 679..680
    research/object_detection/core/batch_multiclass_nms_test.py on lines 681..682

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 48.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

          self.assertAllClose(nmsed_scores[i, 0:num_detections[i]],
                              exp_nms_scores[i, 0:num_detections[i]])
    research/object_detection/core/batch_multiclass_nms_test.py on lines 677..678
    research/object_detection/core/batch_multiclass_nms_test.py on lines 681..682

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 48.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Identical blocks of code found in 2 locations. Consider refactoring.
    Open

        scores = np.array([[[.9, 0.01], [.75, 0.05],
                            [.6, 0.01], [.95, 0],
                            [.5, 0.01], [.3, 0.01],
                            [.01, .85], [.01, .5]]], np.float32)
    Severity: Minor
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 1 other location - About 45 mins to fix
    research/object_detection/core/class_agnostic_nms_test.py on lines 109..110

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 35.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

          (nmsed_boxes, nmsed_scores, nmsed_classes, nmsed_masks,
           nmsed_additional_fields, num_detections
          ) = post_processing.batch_multiclass_non_max_suppression(
              boxes, scores, score_thresh, iou_thresh,
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 2 other locations - About 40 mins to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 475..478
    research/object_detection/core/batch_multiclass_nms_test.py on lines 613..616

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 34.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

          (nmsed_boxes, nmsed_scores, nmsed_classes, nmsed_masks,
           nmsed_additional_fields, num_detections
          ) = post_processing.batch_multiclass_non_max_suppression(
              boxes, scores, score_thresh, iou_thresh,
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 2 other locations - About 40 mins to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 475..478
    research/object_detection/core/batch_multiclass_nms_test.py on lines 557..560

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 34.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

          (nmsed_boxes, nmsed_scores, nmsed_classes, nmsed_masks,
           nmsed_additional_fields, num_detections
          ) = post_processing.batch_multiclass_non_max_suppression(
              boxes, scores, score_thresh, iou_thresh,
    Severity: Major
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 2 other locations - About 40 mins to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 557..560
    research/object_detection/core/batch_multiclass_nms_test.py on lines 613..616

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 34.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

        exp_nms_corners = [[[0, 10, 1, 11],
                            [0, 0, 1, 1],
                            [0, 999, 2, 1004],
                            [0, 100, 1, 101]]]
    Severity: Minor
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 2 other locations - About 30 mins to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 79..81
    research/object_detection/core/class_agnostic_nms_test.py on lines 131..132

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 32.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    Similar blocks of code found in 3 locations. Consider refactoring.
    Open

        expected_iou = [[[0.99999994, 0.0917431, 0.9099099, -1.],
                         [0.0917431, 1., 0.08154944, -1.],
                         [0.9099099, 0.08154944, 1., -1.], [-1., -1., -1., -1.]]]
    Severity: Minor
    Found in research/object_detection/core/batch_multiclass_nms_test.py and 2 other locations - About 30 mins to fix
    research/object_detection/core/batch_multiclass_nms_test.py on lines 48..51
    research/object_detection/core/class_agnostic_nms_test.py on lines 131..132

    Duplicated Code

    Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

    Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

    When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

    Tuning

    This issue has a mass of 32.

    We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

    The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

    If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

    See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

    Refactorings

    Further Reading

    There are no issues that match your filters.

    Category
    Status