Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
N
ngraph
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
ngraph
Commits
e5330c16
Commit
e5330c16
authored
Sep 06, 2019
by
Robert Kimball
Committed by
Scott Cyphers
Sep 06, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Minimize #include in op headers (#3553)
* cleanup op includes in headers * fix missing include
parent
9c9bfa03
Hide whitespace changes
Inline
Side-by-side
Showing
29 changed files
with
53 additions
and
54 deletions
+53
-54
all.cpp
src/ngraph/op/all.cpp
+6
-0
all.hpp
src/ngraph/op/all.hpp
+1
-7
any.cpp
src/ngraph/op/any.cpp
+6
-0
any.hpp
src/ngraph/op/any.hpp
+1
-7
argmax.cpp
src/ngraph/op/argmax.cpp
+1
-0
argmax.hpp
src/ngraph/op/argmax.hpp
+0
-2
argmin.cpp
src/ngraph/op/argmin.cpp
+1
-0
argmin.hpp
src/ngraph/op/argmin.hpp
+0
-2
avg_pool.cpp
src/ngraph/op/avg_pool.cpp
+6
-0
avg_pool.hpp
src/ngraph/op/avg_pool.hpp
+1
-5
batch_norm.hpp
src/ngraph/op/batch_norm.hpp
+0
-1
constant.hpp
src/ngraph/op/constant.hpp
+0
-1
convolution.cpp
src/ngraph/op/convolution.cpp
+5
-0
convolution.hpp
src/ngraph/op/convolution.hpp
+1
-5
embedding_lookup.hpp
src/ngraph/op/embedding_lookup.hpp
+0
-1
erf.hpp
src/ngraph/op/erf.hpp
+0
-2
compiled_kernel.hpp
src/ngraph/op/experimental/compiled_kernel.hpp
+0
-1
generate_mask.cpp
src/ngraph/op/experimental/generate_mask.cpp
+1
-0
generate_mask.hpp
src/ngraph/op/experimental/generate_mask.hpp
+2
-2
max_pool.cpp
src/ngraph/op/max_pool.cpp
+5
-0
max_pool.hpp
src/ngraph/op/max_pool.hpp
+1
-5
product.cpp
src/ngraph/op/product.cpp
+6
-0
product.hpp
src/ngraph/op/product.hpp
+1
-5
quantized_dot.hpp
src/ngraph/op/quantized_dot.hpp
+0
-1
relu.hpp
src/ngraph/op/relu.hpp
+0
-1
sum.cpp
src/ngraph/op/sum.cpp
+6
-0
sum.hpp
src/ngraph/op/sum.hpp
+1
-5
topk.hpp
src/ngraph/op/topk.hpp
+0
-1
cpu_emitter.cpp
src/ngraph/runtime/cpu/cpu_emitter.cpp
+1
-0
No files found.
src/ngraph/op/all.cpp
View file @
e5330c16
...
...
@@ -15,6 +15,7 @@
//*****************************************************************************
#include "ngraph/op/all.hpp"
#include "ngraph/graph_util.hpp"
using
namespace
std
;
using
namespace
ngraph
;
...
...
@@ -38,3 +39,8 @@ shared_ptr<Node> op::All::copy_with_new_args(const NodeVector& new_args) const
check_new_args_count
(
this
,
new_args
);
return
make_shared
<
All
>
(
new_args
.
at
(
0
),
new_args
.
at
(
1
));
}
shared_ptr
<
Node
>
op
::
All
::
get_default_value
()
const
{
return
make_constant_from_string
(
"1"
,
get_element_type
(),
get_shape
());
}
src/ngraph/op/all.hpp
View file @
e5330c16
...
...
@@ -16,9 +16,6 @@
#pragma once
#include "ngraph/axis_set.hpp"
#include "ngraph/graph_util.hpp"
#include "ngraph/op/op.hpp"
#include "ngraph/op/util/logical_reduction.hpp"
namespace
ngraph
...
...
@@ -48,10 +45,7 @@ namespace ngraph
std
::
shared_ptr
<
Node
>
copy_with_new_args
(
const
NodeVector
&
new_args
)
const
override
;
/// \return The default value for All.
virtual
std
::
shared_ptr
<
Node
>
get_default_value
()
const
override
{
return
ngraph
::
make_constant_from_string
(
"1"
,
get_element_type
(),
get_shape
());
}
virtual
std
::
shared_ptr
<
Node
>
get_default_value
()
const
override
;
};
}
}
src/ngraph/op/any.cpp
View file @
e5330c16
...
...
@@ -15,6 +15,7 @@
//*****************************************************************************
#include "ngraph/op/any.hpp"
#include "ngraph/graph_util.hpp"
using
namespace
std
;
using
namespace
ngraph
;
...
...
@@ -38,3 +39,8 @@ shared_ptr<Node> op::Any::copy_with_new_args(const NodeVector& new_args) const
check_new_args_count
(
this
,
new_args
);
return
make_shared
<
Any
>
(
new_args
.
at
(
0
),
new_args
.
at
(
1
));
}
shared_ptr
<
Node
>
op
::
Any
::
get_default_value
()
const
{
return
ngraph
::
make_constant_from_string
(
"0"
,
get_element_type
(),
get_shape
());
}
src/ngraph/op/any.hpp
View file @
e5330c16
...
...
@@ -16,9 +16,6 @@
#pragma once
#include "ngraph/axis_set.hpp"
#include "ngraph/graph_util.hpp"
#include "ngraph/op/op.hpp"
#include "ngraph/op/util/logical_reduction.hpp"
namespace
ngraph
...
...
@@ -49,10 +46,7 @@ namespace ngraph
copy_with_new_args
(
const
NodeVector
&
new_args
)
const
override
;
/// \return The default value for Any.
virtual
std
::
shared_ptr
<
Node
>
get_default_value
()
const
override
{
return
ngraph
::
make_constant_from_string
(
"0"
,
get_element_type
(),
get_shape
());
}
virtual
std
::
shared_ptr
<
Node
>
get_default_value
()
const
override
;
};
}
}
src/ngraph/op/argmax.cpp
View file @
e5330c16
...
...
@@ -15,6 +15,7 @@
//*****************************************************************************
#include "ngraph/op/argmax.hpp"
#include "ngraph/graph_util.hpp"
using
namespace
std
;
using
namespace
ngraph
;
...
...
src/ngraph/op/argmax.hpp
View file @
e5330c16
...
...
@@ -16,8 +16,6 @@
#pragma once
#include "ngraph/axis_set.hpp"
#include "ngraph/graph_util.hpp"
#include "ngraph/op/util/index_reduction.hpp"
namespace
ngraph
...
...
src/ngraph/op/argmin.cpp
View file @
e5330c16
...
...
@@ -15,6 +15,7 @@
//*****************************************************************************
#include "ngraph/op/argmin.hpp"
#include "ngraph/graph_util.hpp"
using
namespace
std
;
using
namespace
ngraph
;
...
...
src/ngraph/op/argmin.hpp
View file @
e5330c16
...
...
@@ -16,8 +16,6 @@
#pragma once
#include "ngraph/axis_set.hpp"
#include "ngraph/graph_util.hpp"
#include "ngraph/op/util/index_reduction.hpp"
namespace
ngraph
...
...
src/ngraph/op/avg_pool.cpp
View file @
e5330c16
...
...
@@ -15,6 +15,7 @@
//*****************************************************************************
#include "ngraph/op/avg_pool.hpp"
#include "ngraph/graph_util.hpp"
#include "ngraph/validation_util.hpp"
using
namespace
std
;
...
...
@@ -224,6 +225,11 @@ shared_ptr<Node> op::AvgPool::copy_with_new_args(const NodeVector& new_args) con
m_ceil_mode
);
}
shared_ptr
<
Node
>
op
::
AvgPool
::
get_default_value
()
const
{
return
ngraph
::
make_constant_from_string
(
"0"
,
get_element_type
(),
get_shape
());
}
const
string
op
::
AvgPoolBackprop
::
type_name
(
"AvgPoolBackprop"
);
op
::
AvgPoolBackprop
::
AvgPoolBackprop
(
const
Shape
&
forward_arg_shape
,
...
...
src/ngraph/op/avg_pool.hpp
View file @
e5330c16
...
...
@@ -16,7 +16,6 @@
#pragma once
#include "ngraph/graph_util.hpp"
#include "ngraph/op/op.hpp"
#include "ngraph/op/util/attr_types.hpp"
...
...
@@ -157,10 +156,7 @@ namespace ngraph
bool
get_ceil_mode
()
const
;
void
set_ceil_mode
(
bool
ceil_mode
);
/// \return The default value for AvgPool.
virtual
std
::
shared_ptr
<
Node
>
get_default_value
()
const
override
{
return
ngraph
::
make_constant_from_string
(
"0"
,
get_element_type
(),
get_shape
());
}
virtual
std
::
shared_ptr
<
Node
>
get_default_value
()
const
override
;
protected
:
Shape
m_window_shape
;
...
...
src/ngraph/op/batch_norm.hpp
View file @
e5330c16
...
...
@@ -21,7 +21,6 @@
#include "ngraph/deprecated.hpp"
#include "ngraph/node.hpp"
#include "ngraph/op/op.hpp"
#include "ngraph/util.hpp"
namespace
ngraph
{
...
...
src/ngraph/op/constant.hpp
View file @
e5330c16
...
...
@@ -22,7 +22,6 @@
#include "ngraph/coordinate_diff.hpp"
#include "ngraph/node.hpp"
#include "ngraph/runtime/aligned_buffer.hpp"
#include "ngraph/type/bfloat16.hpp"
#include "ngraph/type/element_type.hpp"
#include "ngraph/util.hpp"
...
...
src/ngraph/op/convolution.cpp
View file @
e5330c16
...
...
@@ -211,6 +211,11 @@ void op::Convolution::generate_adjoints(autodiff::Adjoints& adjoints, const Node
m_data_dilation_strides
));
}
shared_ptr
<
Node
>
op
::
Convolution
::
get_default_value
()
const
{
return
ngraph
::
make_constant_from_string
(
"0"
,
get_element_type
(),
get_shape
());
}
const
string
op
::
ConvolutionBackpropData
::
type_name
{
"ConvolutionBackpropData"
};
op
::
ConvolutionBackpropData
::
ConvolutionBackpropData
(
const
Shape
&
data_batch_shape
,
...
...
src/ngraph/op/convolution.hpp
View file @
e5330c16
...
...
@@ -17,7 +17,6 @@
#pragma once
#include "ngraph/coordinate_diff.hpp"
#include "ngraph/graph_util.hpp"
#include "ngraph/op/op.hpp"
#include "ngraph/op/util/attr_types.hpp"
...
...
@@ -180,10 +179,7 @@ namespace ngraph
const
PadType
&
get_pad_type
()
const
{
return
m_pad_type
;
}
void
set_pad_type
(
const
PadType
&
pad_type
)
{
m_pad_type
=
pad_type
;
}
/// \return The default value for Convolution.
virtual
std
::
shared_ptr
<
Node
>
get_default_value
()
const
override
{
return
ngraph
::
make_constant_from_string
(
"0"
,
get_element_type
(),
get_shape
());
}
virtual
std
::
shared_ptr
<
Node
>
get_default_value
()
const
override
;
protected
:
Strides
m_window_movement_strides
;
...
...
src/ngraph/op/embedding_lookup.hpp
View file @
e5330c16
...
...
@@ -17,7 +17,6 @@
#pragma once
#include "ngraph/axis_set.hpp"
#include "ngraph/graph_util.hpp"
#include "ngraph/op/util/index_reduction.hpp"
namespace
ngraph
...
...
src/ngraph/op/erf.hpp
View file @
e5330c16
...
...
@@ -16,9 +16,7 @@
#pragma once
#include "ngraph/op/op.hpp"
#include "ngraph/op/util/unary_elementwise_arithmetic.hpp"
#include "ngraph/util.hpp"
namespace
ngraph
{
...
...
src/ngraph/op/experimental/compiled_kernel.hpp
View file @
e5330c16
...
...
@@ -17,7 +17,6 @@
#pragma once
#include "ngraph/op/op.hpp"
#include "ngraph/util.hpp"
namespace
ngraph
{
...
...
src/ngraph/op/experimental/generate_mask.cpp
View file @
e5330c16
...
...
@@ -15,6 +15,7 @@
//*****************************************************************************
#include "ngraph/op/experimental/generate_mask.hpp"
#include "ngraph/op/constant.hpp"
using
namespace
std
;
using
namespace
ngraph
;
...
...
src/ngraph/op/experimental/generate_mask.hpp
View file @
e5330c16
...
...
@@ -17,9 +17,9 @@
#pragma once
#include <memory>
#include "ngraph/op/constant.hpp"
#include "ngraph/op/op.hpp"
#include "ngraph/state/rng_state.hpp"
namespace
ngraph
{
namespace
op
...
...
src/ngraph/op/max_pool.cpp
View file @
e5330c16
...
...
@@ -144,6 +144,11 @@ shared_ptr<Node> op::MaxPool::copy_with_new_args(const NodeVector& new_args) con
m_ceil_mode
);
}
shared_ptr
<
Node
>
op
::
MaxPool
::
get_default_value
()
const
{
return
ngraph
::
make_constant_from_string
(
"0"
,
get_element_type
(),
get_shape
());
}
const
string
op
::
MaxPoolBackprop
::
type_name
{
"MaxPoolBackprop"
};
op
::
MaxPoolBackprop
::
MaxPoolBackprop
(
const
Output
<
Node
>&
arg_forward
,
...
...
src/ngraph/op/max_pool.hpp
View file @
e5330c16
...
...
@@ -16,7 +16,6 @@
#pragma once
#include "ngraph/graph_util.hpp"
#include "ngraph/op/op.hpp"
#include "ngraph/op/util/attr_types.hpp"
...
...
@@ -123,10 +122,7 @@ namespace ngraph
bool
get_ceil_mode
()
const
{
return
m_ceil_mode
;
}
void
set_ceil_mode
(
bool
ceil_mode
)
{
m_ceil_mode
=
ceil_mode
;
}
/// \return The default value for MaxPool.
virtual
std
::
shared_ptr
<
Node
>
get_default_value
()
const
override
{
return
ngraph
::
make_constant_from_string
(
"0"
,
get_element_type
(),
get_shape
());
}
virtual
std
::
shared_ptr
<
Node
>
get_default_value
()
const
override
;
protected
:
virtual
void
generate_adjoints
(
autodiff
::
Adjoints
&
adjoints
,
...
...
src/ngraph/op/product.cpp
View file @
e5330c16
...
...
@@ -15,6 +15,7 @@
//*****************************************************************************
#include "ngraph/op/product.hpp"
#include "ngraph/graph_util.hpp"
using
namespace
std
;
using
namespace
ngraph
;
...
...
@@ -38,3 +39,8 @@ shared_ptr<Node> op::Product::copy_with_new_args(const NodeVector& new_args) con
check_new_args_count
(
this
,
new_args
);
return
make_shared
<
Product
>
(
new_args
.
at
(
0
),
get_reduction_axes
());
}
shared_ptr
<
Node
>
op
::
Product
::
get_default_value
()
const
{
return
ngraph
::
make_constant_from_string
(
"1"
,
get_element_type
(),
get_shape
());
}
src/ngraph/op/product.hpp
View file @
e5330c16
...
...
@@ -16,7 +16,6 @@
#pragma once
#include "ngraph/graph_util.hpp"
#include "ngraph/op/util/arithmetic_reduction.hpp"
namespace
ngraph
...
...
@@ -46,10 +45,7 @@ namespace ngraph
Product
(
const
Output
<
Node
>&
arg
,
const
Output
<
Node
>&
reduction_axes
);
/// \return The default value for Product.
virtual
std
::
shared_ptr
<
Node
>
get_default_value
()
const
override
{
return
ngraph
::
make_constant_from_string
(
"1"
,
get_element_type
(),
get_shape
());
}
virtual
std
::
shared_ptr
<
Node
>
get_default_value
()
const
override
;
virtual
std
::
shared_ptr
<
Node
>
copy_with_new_args
(
const
NodeVector
&
new_args
)
const
override
;
...
...
src/ngraph/op/quantized_dot.hpp
View file @
e5330c16
...
...
@@ -16,7 +16,6 @@
#pragma once
#include "ngraph/coordinate_diff.hpp"
#include "ngraph/op/op.hpp"
namespace
ngraph
...
...
src/ngraph/op/relu.hpp
View file @
e5330c16
...
...
@@ -20,7 +20,6 @@
#include "ngraph/op/op.hpp"
#include "ngraph/op/util/binary_elementwise_arithmetic.hpp"
#include "ngraph/op/util/unary_elementwise_arithmetic.hpp"
#include "ngraph/util.hpp"
#include <memory>
...
...
src/ngraph/op/sum.cpp
View file @
e5330c16
...
...
@@ -15,6 +15,7 @@
//*****************************************************************************
#include "ngraph/op/sum.hpp"
#include "ngraph/graph_util.hpp"
#include "ngraph/op/broadcast.hpp"
using
namespace
std
;
...
...
@@ -49,3 +50,8 @@ void op::Sum::generate_adjoints(autodiff::Adjoints& adjoints, const NodeVector&
adjoints
.
add_delta
(
x
,
make_shared
<
op
::
Broadcast
>
(
delta
,
x_shape
,
get_reduction_axes
()));
}
shared_ptr
<
Node
>
op
::
Sum
::
get_default_value
()
const
{
return
ngraph
::
make_constant_from_string
(
"0"
,
get_element_type
(),
get_shape
());
}
src/ngraph/op/sum.hpp
View file @
e5330c16
...
...
@@ -17,7 +17,6 @@
#pragma once
#include "ngraph/axis_set.hpp"
#include "ngraph/graph_util.hpp"
#include "ngraph/op/op.hpp"
#include "ngraph/op/util/arithmetic_reduction.hpp"
...
...
@@ -96,10 +95,7 @@ namespace ngraph
copy_with_new_args
(
const
NodeVector
&
new_args
)
const
override
;
/// \return The default value for Sum.
virtual
std
::
shared_ptr
<
Node
>
get_default_value
()
const
override
{
return
ngraph
::
make_constant_from_string
(
"0"
,
get_element_type
(),
get_shape
());
}
virtual
std
::
shared_ptr
<
Node
>
get_default_value
()
const
override
;
protected
:
virtual
void
generate_adjoints
(
autodiff
::
Adjoints
&
adjoints
,
...
...
src/ngraph/op/topk.hpp
View file @
e5330c16
...
...
@@ -19,7 +19,6 @@
#include <memory>
#include "ngraph/axis_set.hpp"
#include "ngraph/graph_util.hpp"
#include "ngraph/op/op.hpp"
namespace
ngraph
...
...
src/ngraph/runtime/cpu/cpu_emitter.cpp
View file @
e5330c16
...
...
@@ -130,6 +130,7 @@
#include "ngraph/runtime/cpu/op/rnn.hpp"
#include "ngraph/runtime/cpu/op/sigmoid_mul.hpp"
#include "ngraph/runtime/cpu/op/update_slice.hpp"
#include "ngraph/state/rng_state.hpp"
#include "ngraph/type/element_type.hpp"
#include "ngraph/util.hpp"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment