Commit c68d9147 authored by Chao Liu's avatar Chao Liu
Browse files

testing

parent 0c24e527
...@@ -18,7 +18,22 @@ int main(int argc, char* argv[]) ...@@ -18,7 +18,22 @@ int main(int argc, char* argv[])
{ {
using namespace ck; using namespace ck;
#if 0 #if 1
// 1x1, 8x8
constexpr index_t N = 2;
constexpr index_t C = 128;
constexpr index_t HI = 8;
constexpr index_t WI = 8;
constexpr index_t K = 128;
constexpr index_t Y = 1;
constexpr index_t X = 1;
using ConvStrides = Sequence<1, 1>;
using ConvDilations = Sequence<1, 1>;
using LeftPads = Sequence<0, 0>;
using RightPads = Sequence<0, 0>;
#elif 0
// 3x3, 71x71 // 3x3, 71x71
constexpr index_t N = 128; constexpr index_t N = 128;
constexpr index_t C = 192; constexpr index_t C = 192;
...@@ -33,7 +48,7 @@ int main(int argc, char* argv[]) ...@@ -33,7 +48,7 @@ int main(int argc, char* argv[])
using LeftPads = Sequence<1, 1>; using LeftPads = Sequence<1, 1>;
using RightPads = Sequence<1, 1>; using RightPads = Sequence<1, 1>;
#elif 0 #elif 1
// 1x1, 8x8 // 1x1, 8x8
constexpr index_t N = 128; constexpr index_t N = 128;
constexpr index_t C = 1536; constexpr index_t C = 1536;
...@@ -108,7 +123,7 @@ int main(int argc, char* argv[]) ...@@ -108,7 +123,7 @@ int main(int argc, char* argv[])
using LeftPads = Sequence<3, 0>; using LeftPads = Sequence<3, 0>;
using RightPads = Sequence<3, 0>; using RightPads = Sequence<3, 0>;
#elif 0 #elif 1
// 1x7, 17x17 // 1x7, 17x17
constexpr index_t N = 128; constexpr index_t N = 128;
constexpr index_t C = 128; constexpr index_t C = 128;
...@@ -198,7 +213,7 @@ int main(int argc, char* argv[]) ...@@ -198,7 +213,7 @@ int main(int argc, char* argv[])
using LeftPads = Sequence<0, 0>; using LeftPads = Sequence<0, 0>;
using RightPads = Sequence<0, 0>; using RightPads = Sequence<0, 0>;
#elif 1 #elif 0
// 3x3, 35x35, stride 2 // 3x3, 35x35, stride 2
constexpr index_t N = 128; constexpr index_t N = 128;
constexpr index_t C = 256; constexpr index_t C = 256;
...@@ -526,14 +541,14 @@ int main(int argc, char* argv[]) ...@@ -526,14 +541,14 @@ int main(int argc, char* argv[])
if(do_verification) if(do_verification)
{ {
#if 0 #if 1
col_eb.GenerateTensorValue(GeneratorTensor_1{}, num_thread); col_eb.GenerateTensorValue(GeneratorTensor_1{}, num_thread);
#else #else
col_eb.GenerateTensorValue(GeneratorTensor_2{-5, 5}, num_thread); col_eb.GenerateTensorValue(GeneratorTensor_2{-5, 5}, num_thread);
#endif #endif
} }
#if 1 #if 0
device_col2im_eb_nchw(col_eb_desc, device_col2im_eb_nchw(col_eb_desc,
col_eb, col_eb,
img_nchw_desc, img_nchw_desc,
...@@ -572,7 +587,7 @@ int main(int argc, char* argv[]) ...@@ -572,7 +587,7 @@ int main(int argc, char* argv[])
check_error(img_nchw_host, img_nchw_device); check_error(img_nchw_host, img_nchw_device);
#if 0 #if 1
LogRange(std::cout << "col_eb : ", col_eb.mData, ",") << std::endl; LogRange(std::cout << "col_eb : ", col_eb.mData, ",") << std::endl;
LogRange(std::cout << "img_nchw_host : ", img_nchw_host.mData, ",") << std::endl; LogRange(std::cout << "img_nchw_host : ", img_nchw_host.mData, ",") << std::endl;
LogRange(std::cout << "img_nchw_device : ", img_nchw_device.mData, ",") << std::endl; LogRange(std::cout << "img_nchw_device : ", img_nchw_device.mData, ",") << std::endl;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment