concat.cpp 730 Bytes
Newer Older
Paul's avatar
Paul committed
1
#include <migraphx/gpu/concat.hpp>
Paul's avatar
Paul committed
2
#include <migraphx/gpu/context.hpp>
Paul's avatar
Paul committed
3
#include <migraphx/gpu/device/concat.hpp>
4

Paul's avatar
Paul committed
5
namespace migraphx {
Paul's avatar
Paul committed
6
inline namespace MIGRAPHX_INLINE_NS {
7
8
namespace gpu {

wsttiger's avatar
wsttiger committed
9
shape hip_concat::compute_shape(std::vector<shape> inputs) const
10
11
12
13
14
{
    inputs.pop_back();
    return op.compute_shape(inputs);
}

Paul's avatar
Paul committed
15
16
17
argument hip_concat::compute(context& ctx,
                             const shape& output_shape,
                             const std::vector<argument>& args) const
18
{
19
    std::vector<std::size_t> offsets = op.compute_offsets(output_shape, args);
Paul's avatar
Paul committed
20
    return device::concat(ctx.get_stream().get(), output_shape, args, offsets);
21
22
23
}

} // namespace gpu
Paul's avatar
Paul committed
24
} // namespace MIGRAPHX_INLINE_NS
Paul's avatar
Paul committed
25
} // namespace migraphx