Skip to content

Commit

Permalink
Merge branch 'master' into an/correct_scheduler
Browse files Browse the repository at this point in the history
  • Loading branch information
allnes authored Sep 25, 2023
2 parents 720a1c2 + bf7fcb0 commit ee7e1aa
Show file tree
Hide file tree
Showing 332 changed files with 7,568 additions and 2,702 deletions.
812 changes: 410 additions & 402 deletions .github/workflows/linux.yml

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion .github/workflows/linux_debian.yml
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ jobs:
- name: ONNX frontend tests
run: |
export LD_LIBRARY_PATH=${{ env.INSTALL_TEST_DIR }}:$LD_LIBRARY_PATH
${{ env.INSTALL_TEST_DIR }}/ov_onnx_frontend_tests --gtest_print_time=1 --gtest_filter=-*IE_GPU*:*FrontEndLoadFromTest.testLoadFromTwoStreams*:*FrontEndLoadFromTest.testLoadFromTwoFiles* \
${{ env.INSTALL_TEST_DIR }}/ov_onnx_frontend_tests --gtest_print_time=1 --gtest_filter=-*IE_GPU* \
--gtest_output=xml:${{ env.INSTALL_TEST_DIR }}/TEST-ONNXFrontend.xml
- name: TensorFlow frontend tests
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/mo.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ jobs:
runs-on: ubuntu-22.04
steps:
- name: Clone OpenVINO
- uses: actions/checkout@v4
uses: actions/checkout@v4

- name: Setup Python
uses: actions/setup-python@v4
Expand Down
10 changes: 8 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ function(openvino_developer_export_targets)
endfunction()

# add target with processed tests model zoo
if (ENABLE_TESTS)
if(ENABLE_TESTS)
include(cmake/test_model_zoo.cmake)
endif()

Expand All @@ -135,15 +135,21 @@ if(ENABLE_SAMPLES OR ENABLE_TESTS)
endif()

# Enable interpreter backend for tests
if (ENABLE_TESTS OR ENABLE_TEMPLATE)
if(ENABLE_TESTS OR ENABLE_TEMPLATE)
add_subdirectory(src/plugins/template/backend)
endif()

include(cmake/extra_modules.cmake)
add_subdirectory(docs)
add_subdirectory(tools)
add_subdirectory(scripts)
add_subdirectory(licensing)

if(ENABLE_TESTS)
# layers and other more high-level / e2e tests
add_subdirectory(tests)
endif()

#
# CPack
#
Expand Down
12 changes: 6 additions & 6 deletions cmake/test_model_zoo.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -72,23 +72,23 @@ function(ov_model_convert SRC DST OUT)
endfunction()

if(OV_GENERATOR_MULTI_CONFIG AND CMAKE_VERSION VERSION_GREATER_EQUAL 3.20)
set(test_model_zoo_output_dir "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/$<CONFIG>/test_model_zoo")
set(TEST_MODEL_ZOO_OUTPUT_DIR "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/$<CONFIG>/test_model_zoo" CACHE PATH "")
else()
set(test_model_zoo_output_dir "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/test_model_zoo")
set(TEST_MODEL_ZOO_OUTPUT_DIR "${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/test_model_zoo" CACHE PATH "")
endif()

ov_model_convert("${CMAKE_CURRENT_SOURCE_DIR}/src/core/tests"
"${test_model_zoo_output_dir}/core"
"${TEST_MODEL_ZOO_OUTPUT_DIR}/core"
core_tests_out_files)

set(rel_path "src/tests/functional/plugin/shared/models")
ov_model_convert("${OpenVINO_SOURCE_DIR}/${rel_path}"
"${test_model_zoo_output_dir}/func_tests/models"
"${TEST_MODEL_ZOO_OUTPUT_DIR}/func_tests/models"
ft_out_files)

set(rel_path "src/frontends/onnx/tests/models")
ov_model_convert("${OpenVINO_SOURCE_DIR}/${rel_path}"
"${test_model_zoo_output_dir}/onnx"
"${TEST_MODEL_ZOO_OUTPUT_DIR}/onnx"
onnx_fe_out_files)

if(ENABLE_TESTS)
Expand All @@ -101,7 +101,7 @@ if(ENABLE_TESTS)
# add_dependencies(test_model_zoo paddle_test_models)
#endif()

install(DIRECTORY "${test_model_zoo_output_dir}"
install(DIRECTORY "${TEST_MODEL_ZOO_OUTPUT_DIR}"
DESTINATION tests COMPONENT tests EXCLUDE_FROM_ALL)

set(TEST_MODEL_ZOO "./test_model_zoo" CACHE PATH "Path to test model zoo")
Expand Down
5 changes: 5 additions & 0 deletions docs/OV_Runtime_UG/Operations_specifications.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,10 @@
BatchNormInference-5 <openvino_docs_ops_normalization_BatchNormInference_5>
BatchToSpace-2 <openvino_docs_ops_movement_BatchToSpace_2>
BinaryConvolution-1 <openvino_docs_ops_convolution_BinaryConvolution_1>
BitwiseAnd-13 <openvino_docs_ops_bitwise_BitwiseAnd_13>
BitwiseNot-13 <openvino_docs_ops_bitwise_BitwiseNot_13>
BitwiseOr-13 <openvino_docs_ops_bitwise_BitwiseOr_13>
BitwiseXor-13 <openvino_docs_ops_bitwise_BitwiseXor_13>
Broadcast-1 <openvino_docs_ops_movement_Broadcast_1>
Broadcast-3 <openvino_docs_ops_movement_Broadcast_3>
Bucketize-3 <openvino_docs_ops_condition_Bucketize_3>
Expand Down Expand Up @@ -124,6 +128,7 @@
Mod-1 <openvino_docs_ops_arithmetic_Mod_1>
MulticlassNonMaxSuppression-8 <openvino_docs_ops_sort_MulticlassNonMaxSuppression_8>
MulticlassNonMaxSuppression-9 <openvino_docs_ops_sort_MulticlassNonMaxSuppression_9>
Multinomial-13 <openvino_docs_ops_generation_Multinomial_13>
Multiply-1 <openvino_docs_ops_arithmetic_Multiply_1>
Negative-1 <openvino_docs_ops_arithmetic_Negative_1>
NMSRotated-13 <openvino_docs_ops_sort_NMSRotated_13>
Expand Down
138 changes: 138 additions & 0 deletions docs/ops/bitwise/BitwiseAnd_13.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,138 @@
# BitwiseAnd {#openvino_docs_ops_bitwise_BitwiseAnd_13}

@sphinxdirective

.. meta::
:description: Learn about BitwiseAnd-13 - an element-wise, bitwise AND operation, which can be performed on two required input tensors.

**Versioned name**: *BitwiseAnd-13*

**Category**: *Bitwise binary*

**Short description**: *BitwiseAnd* performs a bitwise logical AND operation with two given tensors element-wise, applying multi-directional broadcast rules.

**Detailed description**: Before performing the operation, input tensors *a* and *b* are broadcasted if their shapes are different and the ``auto_broadcast`` attribute is not ``none``. Broadcasting is performed according to the ``auto_broadcast`` value.

After broadcasting input tensors *a* and *b*, *BitwiseAnd* performs a bitwise logical AND operation for each corresponding element in the given tensors, based on the following algorithm.

For ``boolean`` type tensors, BitwiseAnd is equivalent to :doc:`LogicalAnd <openvino_docs_ops_logical_LogicalAnd_1>`.

If tensor is of ``any supported integer`` type, for each element of the tensor:

1. Convert values from input tensors to their binary representation according to the input tensor datatype.
2. Perform a logical AND on each bit in the binary representation of values from *a* and *b*, where value ``0`` represents ``false`` and value ``1`` represents ``true``.
3. Convert the results of AND in binary representation to the input datatype.

Example 1 - *BitwiseAnd* output for boolean tensor:

.. code-block:: py
:force:

# For given boolean inputs:
a = [True, False, False]
b = [True, True, False]
# Perform logical AND operation same as in LogicalAnd operator:
output = [True, False, False]

Example 2 - *BitwiseAnd* output for uint8 tensor:

.. code-block:: py
:force:

# For given uint8 inputs:
a = [21, 120]
b = [3, 37]
# Create a binary representation of uint8:
# binary a: [00010101, 01111000]
# binary b: [00000011, 00100101]
# Perform bitwise AND of corresponding elements in a and b:
# [00000001, 00100000]
# Convert binary values to uint8:
output = [1, 32]

**Attributes**:

* *auto_broadcast*

* **Description**: specifies the rules used for auto-broadcasting of input tensors.
* **Range of values**:

* *none* - no auto-broadcasting is allowed, all input shapes must match,
* *numpy* - numpy broadcasting rules, description is available in :doc:`Broadcast Rules For Elementwise Operations <openvino_docs_ops_broadcast_rules>`,
* *pdpd* - PaddlePaddle-style implicit broadcasting, description is available in :doc:`Broadcast Rules For Elementwise Operations <openvino_docs_ops_broadcast_rules>`.

* **Type**: string
* **Default value**: "numpy"
* **Required**: *no*

**Inputs**

* **1**: A tensor of type *T* and arbitrary shape. **Required.**
* **2**: A tensor of type *T* and arbitrary shape. **Required.**

**Outputs**

* **1**: The result of element-wise *BitwiseAnd* operation. A tensor of type *T* and the same shape equal to the broadcasted shape of two inputs.

**Types**

* *T*: ``any supported integer or boolean type``.

**Examples**

*Example 1: no broadcast*

.. code-block:: xml
:force:

<layer ... type="BitwiseAnd">
<input>
<port id="0">
<dim>256</dim>
<dim>56</dim>
</port>
<port id="1">
<dim>256</dim>
<dim>56</dim>
</port>
</input>
<output>
<port id="2">
<dim>256</dim>
<dim>56</dim>
</port>
</output>
</layer>


*Example 2: numpy broadcast*

.. code-block:: xml
:force:

<layer ... type="BitwiseAnd">
<input>
<port id="0">
<dim>8</dim>
<dim>1</dim>
<dim>6</dim>
<dim>1</dim>
</port>
<port id="1">
<dim>7</dim>
<dim>1</dim>
<dim>5</dim>
</port>
</input>
<output>
<port id="2">
<dim>8</dim>
<dim>7</dim>
<dim>6</dim>
<dim>5</dim>
</port>
</output>
</layer>


@endsphinxdirective
83 changes: 83 additions & 0 deletions docs/ops/bitwise/BitwiseNot_13.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,83 @@
# BitwiseNot {#openvino_docs_ops_bitwise_BitwiseNot_13}

@sphinxdirective

.. meta::
:description: Learn about BitwiseNot-13 - an element-wise, bitwise negation operation, which can be performed on a single input tensor.

**Versioned name**: *BitwiseNot-13*

**Category**: *Bitwise unary*

**Short description**: *BitwiseNot* performs a bitwise logical negation operation with given tensor element-wise.

**Detailed description**: *BitwiseNot* performs a bitwise logical negation operation for each element in the given tensor, based on the following algorithm.

For ``boolean`` type tensors, BitwiseNot is equivalent to :doc:`LogicalNot <openvino_docs_ops_logical_LogicalNot_1>`.

If tensor is of ``any supported integer`` type, for each element of the tensor:

1. Convert the value from the input tensor to binary representation according to the input tensor datatype.
2. Perform a logical negation on each bit in the binary representation, where value ``0`` represents ``false`` and value ``1`` represents ``true``.
3. Convert back the binary representation to the input datatype.

Example 1 - *BitwiseNot* output for boolean tensor:

.. code-block:: py
:force:

# For given boolean input:
input = [True, False]
# Perform logical negation operation same as in LogicalNot operator:
output = [False, True]

Example 2 - *BitwiseNot* output for uint8 tensor:

.. code-block:: py
:force:

# For given uint8 input:
input = [1, 3]
# Create a binary representation of uint8:
# [00000001, 00000011]
# Perform bitwise negation:
# [11111110, 11111100]
# Convert back binary values to uint8:
output = [254, 252]

**Attributes**: *BitwiseNot* operation has no attributes.

**Inputs**

* **1**: A tensor of type *T* and arbitrary shape. **Required.**

**Outputs**

* **1**: The result of bitwise logical negation operation. A tensor of type *T* and the same shape as the input tensor.

**Types**

* *T*: ``any supported integer or boolean type``.

**Example**

.. code-block:: xml
:force:

<layer ... type="BitwiseNot">
<input>
<port id="0">
<dim>256</dim>
<dim>56</dim>
</port>
</input>
<output>
<port id="1">
<dim>256</dim>
<dim>56</dim>
</port>
</output>
</layer>


@endsphinxdirective
Loading

0 comments on commit ee7e1aa

Please sign in to comment.