Skip to content

Commit

Permalink
cleanup #2
Browse files Browse the repository at this point in the history
  • Loading branch information
alvoron committed Mar 2, 2023
1 parent effdb09 commit c16e8b7
Show file tree
Hide file tree
Showing 8 changed files with 11 additions and 308 deletions.
130 changes: 0 additions & 130 deletions src/plugins/intel_cpu/src/nodes/executors/dnnl/dnnl_pooling.cpp

This file was deleted.

116 changes: 0 additions & 116 deletions src/plugins/intel_cpu/src/nodes/executors/dnnl/dnnl_pooling.hpp

This file was deleted.

1 change: 0 additions & 1 deletion src/plugins/intel_cpu/src/nodes/executors/pooling.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@ struct PoolingAttrs {
std::vector<ptrdiff_t> stride;
std::vector<ptrdiff_t> kernel;
std::vector<ptrdiff_t> dilation;
//ov::Strides dilation;

std::vector<ptrdiff_t> data_pad_begin;
std::vector<ptrdiff_t> data_pad_end;
Expand Down
1 change: 0 additions & 1 deletion src/plugins/intel_cpu/src/nodes/executors/pooling_list.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ namespace intel_cpu {
const std::vector<PoolingExecutorDesc>& getPoolingExecutorsList() {
static std::vector<PoolingExecutorDesc> descs = {
OV_CPU_INSTANCE_ACL(ExecutorType::Acl, std::make_shared<AclPoolingExecutorBuilder>())
//OV_CPU_INSTANCE_DNNL(ExecutorType::Dnnl, std::make_shared<DnnlPoolingExecutorBuilder>())
};

return descs;
Expand Down
2 changes: 0 additions & 2 deletions src/plugins/intel_cpu/src/nodes/executors/pooling_list.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@
#include "acl/acl_pooling.hpp"
#endif

//#include "dnnl/dnnl_matmul.hpp"

namespace ov {
namespace intel_cpu {

Expand Down
24 changes: 11 additions & 13 deletions src/plugins/intel_cpu/src/nodes/pooling.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,17 @@

#include "pooling.h"

#include <dnnl_extension_utils.h>
#include <memory_desc/cpu_memory_desc_utils.h>
#include <onednn/dnnl.h>
#include <utils/general_utils.h>

#include <common/primitive_hashing_utils.hpp>
#include "fake_quantize.h"
#include "conv.h"
#include "concat.h"
#include <string>
#include <vector>

#include "concat.h"
#include "conv.h"
#include "fake_quantize.h"
#include <onednn/dnnl.h>
#include <dnnl_extension_utils.h>
#include <utils/general_utils.h>
#include <memory_desc/cpu_memory_desc_utils.h>
#include "memory_desc/dnnl_blocked_memory_desc.h"
#include <common/primitive_hashing_utils.hpp>

#if defined(OV_CPU_WITH_ACL)
# include "executors/acl/acl_utils.hpp"
Expand Down Expand Up @@ -553,8 +551,8 @@ dnnl::algorithm Pooling::getPoolingAlgorithm() const {

std::shared_ptr<pooling_v2_forward::desc> Pooling::createDescriptorInternal(
const dnnl::memory::desc& in_candidate,
const dnnl::memory::desc& out_candidate,
const dnnl::algorithm alg) const {
const dnnl::memory::desc& out_candidate,
const dnnl::algorithm alg) const {
return createDescriptorHelper(in_candidate,
out_candidate,
alg,
Expand Down Expand Up @@ -669,7 +667,7 @@ void Pooling::initSupportedPrimitiveDescriptors() {
}
}
}
}
}

void Pooling::initDescriptor(const NodeConfig& config) {
if (useACL)
Expand Down
25 changes: 0 additions & 25 deletions src/plugins/intel_cpu/src/nodes/pooling.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,33 +54,8 @@ class Pooling : public Node {
const dnnl::algorithm alg) const;

AttrPtr pAttr;

Shape inShape;

bool useACL = false;
//bool isMaxPool8 = false;
//bool auto_pad = false;
//bool exclude_pad = false;
//std::vector<ptrdiff_t> dilation;
//std::vector<ptrdiff_t> stride;
//std::vector<ptrdiff_t> kernel;

/// Effective padding. Used to define correct output shape by oneDNN
/// reshape formula: (iw - kernel + pad_l + pad_r) / strides[i - 2] + 1
/// should be passed into pooling desc constructor.
//std::vector<ptrdiff_t> effective_pad_begin;
//std::vector<ptrdiff_t> effective_pad_end;

/// Effective dilation. Used to define correct dilation for OneDNN.
/// For OneDNN default dilation is vector of zero
//std::vector<ptrdiff_t> effective_dilation;

/// Effective pad value. Describe how much zero element added to input
/// data tensor. May be less than "Effective padding" values.
/// If pooling window is out of this padding, the region of averaging
/// is decreased.
//std::vector<ptrdiff_t> data_pad_begin;
//std::vector<ptrdiff_t> data_pad_end;
};

} // namespace node
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,15 +116,6 @@ class PoolingLayerCPUTest : public testing::WithParamInterface<poolLayerCpuTestP
poolInput = ngraph::builder::makeFakeQuantize(poolInput, inPrc, 256, newShape);
}

std::cout << "creating node in test: " << std::endl;
std::cout << "kernel" << CommonTestUtils::vec2str(kernel) << "_";
std::cout << "stride" << CommonTestUtils::vec2str(stride) << "_";
std::cout << "excludePad" << excludePad << "_";
std::cout << "padBegin" << CommonTestUtils::vec2str(padBegin) << "_";
std::cout << "padEnd" << CommonTestUtils::vec2str(padEnd) << "_";
std::cout << "roundingType=" << roundingType << "_";
std::cout << "padType=" << padType << "_";

std::shared_ptr<ngraph::Node> pooling = ngraph::builder::makePooling(poolInput,
stride,
padBegin,
Expand Down Expand Up @@ -203,17 +194,6 @@ class MaxPoolingV8LayerCPUTest : public testing::WithParamInterface<maxPoolV8Lay

init_input_shapes({inputShapes});

std::cout << "creating MaxPoolingV8 node in test: " << std::endl;
std::cout << "kernel" << CommonTestUtils::vec2str(kernel) << "_";
std::cout << "stride" << CommonTestUtils::vec2str(stride) << "_";
std::cout << "dilation" << CommonTestUtils::vec2str(dilation) << "_";
std::cout << "padBegin" << CommonTestUtils::vec2str(padBegin) << "_";
std::cout << "padEnd" << CommonTestUtils::vec2str(padEnd) << "_";
std::cout << "roundingType=" << roundingType << "_";
std::cout << "padType=" << padType << "_";
std::cout << "indexElementType=" << indexElementType << "_";
std::cout << "axis=" << axis << "_";

auto params = ngraph::builder::makeDynamicParams(inPrc, inputDynamicShapes);
std::shared_ptr<ngraph::Node> pooling = ngraph::builder::makeMaxPoolingV8(params[0], stride, dilation, padBegin, padEnd,
kernel, roundingType, padType,
Expand Down

0 comments on commit c16e8b7

Please sign in to comment.