Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
gaoqiong
composable_kernel
Commits
991ce41a
You need to sign in or sign up before continuing.
Commit
991ce41a
authored
Oct 17, 2023
by
Astha Rai
Browse files
minor formatting and naming fixes
parent
09b0780d
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
7 deletions
+4
-7
client_example/23_elementwise_transpose/elementwise_transpose_3d.cpp
...ple/23_elementwise_transpose/elementwise_transpose_3d.cpp
+3
-5
library/include/ck/library/tensor_operation_instance/gpu/transpose_3d.hpp
...ck/library/tensor_operation_instance/gpu/transpose_3d.hpp
+1
-2
No files found.
client_example/23_elementwise_transpose/elementwise_transpose_3d.cpp
View file @
991ce41a
...
@@ -37,8 +37,6 @@ struct SimpleDeviceMem
...
@@ -37,8 +37,6 @@ struct SimpleDeviceMem
int
main
()
int
main
()
{
{
bool
time_kernel
=
true
;
const
int
N
=
16
;
const
int
N
=
16
;
const
int
C
=
8
;
const
int
C
=
8
;
const
int
D
=
8
;
const
int
D
=
8
;
...
@@ -47,12 +45,12 @@ int main()
...
@@ -47,12 +45,12 @@ int main()
std
::
vector
<
std
::
size_t
>
ncdhw
=
{
N
,
C
,
D
,
H
,
W
};
std
::
vector
<
std
::
size_t
>
ncdhw
=
{
N
,
C
,
D
,
H
,
W
};
std
::
vector
<
std
::
size_t
>
nchwd
=
{
N
,
C
,
H
,
W
,
D
};
std
::
vector
<
std
::
size_t
>
nchwd
=
{
N
,
C
,
H
,
W
,
D
};
Tensor
<
ADataType
>
a
(
ncdhw
);
//
Tensor<ADataType> a(ncdhw);
Tensor
<
BDataType
>
b
(
nchwd
);
//
Tensor<BDataType> b(nchwd);
auto
size
=
N
*
C
*
D
*
H
*
W
;
auto
size
=
N
*
C
*
D
*
H
*
W
;
a
.
GenerateTensorValue
(
GeneratorTensor_3
<
ADataType
>
{
0.0
,
1.0
});
//
a.GenerateTensorValue(GeneratorTensor_3<ADataType>{0.0, 1.0});
std
::
array
<
ck
::
index_t
,
5
>
ab_lengths
{
N
,
C
,
H
,
W
,
D
};
std
::
array
<
ck
::
index_t
,
5
>
ab_lengths
{
N
,
C
,
H
,
W
,
D
};
std
::
array
<
ck
::
index_t
,
5
>
a_strides
=
{
C
*
D
*
H
*
W
,
D
*
H
*
W
,
1
,
D
*
H
,
D
};
std
::
array
<
ck
::
index_t
,
5
>
a_strides
=
{
C
*
D
*
H
*
W
,
D
*
H
*
W
,
1
,
D
*
H
,
D
};
...
...
library/include/ck/library/tensor_operation_instance/gpu/transpose_3d.hpp
View file @
991ce41a
...
@@ -37,7 +37,7 @@ struct DeviceOperationInstanceFactory<
...
@@ -37,7 +37,7 @@ struct DeviceOperationInstanceFactory<
DeviceElementwise
<
InDataTypeTuple
,
OutDataTypeTuple
,
ElementwiseOperation
,
NumDim
>>
DeviceElementwise
<
InDataTypeTuple
,
OutDataTypeTuple
,
ElementwiseOperation
,
NumDim
>>
{
{
using
DeviceOp
=
using
DeviceOp
=
DeviceElementwise
3dImpl
<
InDataTypeTuple
,
OutDataTypeTuple
,
ElementwiseOperation
,
NumDim
>
;
DeviceElementwise
<
InDataTypeTuple
,
OutDataTypeTuple
,
ElementwiseOperation
,
NumDim
>
;
static
auto
GetInstances
()
static
auto
GetInstances
()
{
{
...
@@ -52,7 +52,6 @@ struct DeviceOperationInstanceFactory<
...
@@ -52,7 +52,6 @@ struct DeviceOperationInstanceFactory<
}
}
}
}
return
op_ptrs
;
return
op_ptrs
;
}
};
};
}
// namespace instance
}
// namespace instance
...
...
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