concat.cpp 681 Bytes
Newer Older
1
2
3
4
5
6
7
8
9
10
#include <migraph/gpu/concat.hpp>
#include <migraph/operators.hpp>
#include <migraph/manage_ptr.hpp>
#include <migraph/gpu/miopen.hpp>
#include <migraph/gpu/device/concat.hpp>
#include <utility>

namespace migraph {
namespace gpu {

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

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

} // namespace gpu

} // namespace migraph