convert_fp32_to_fp16.hpp
1 //*****************************************************************************
2 // Copyright 2017-2021 Intel Corporation
3 //
4 // Licensed under the Apache License, Version 2.0 (the "License");
5 // you may not use this file except in compliance with the License.
6 // You may obtain a copy of the License at
7 //
8 // http://www.apache.org/licenses/LICENSE-2.0
9 //
10 // Unless required by applicable law or agreed to in writing, software
11 // distributed under the License is distributed on an "AS IS" BASIS,
12 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 // See the License for the specific language governing permissions and
14 // limitations under the License.
15 //*****************************************************************************
16 
17 #pragma once
18 
19 #include <ngraph/pass/graph_rewrite.hpp>
20 
21 namespace ngraph
22 {
23  namespace pass
24  {
26  {
27  public:
28  NGRAPH_RTTI_DECLARATION;
30  : GraphRewrite()
31  {
32  convert_constants_precision();
33  convert_parameters_precision();
34  }
35 
36  private:
37  void convert_constants_precision();
38 
39  void convert_parameters_precision();
40  };
41  } // namespace pass
42 } // namespace ngraph
Definition: convert_fp32_to_fp16.hpp:26
GraphRewrite is a container for MatcherPasses that allows to run them on Function in efficient way.
Definition: graph_rewrite.hpp:131
The Intel nGraph C++ API.
Definition: attribute_adapter.hpp:28