Skip to content

Commit

Permalink
Allocate sufficient memory for Hungarian if number of batches > 1 (#531)
Browse files Browse the repository at this point in the history
Addresses Hungarian bug described in #528.

The `dualUpdate` method was originally using an array of size one which was eventually changed to a scalar.  It really needs to be an array of size SP (number of subproblems in Date/Nagi nomenclature, number of batches as integrated into raft).

Authors:
  - Chuck Hastings (https://github.com/ChuckHastings)

Approvers:
  - Corey J. Nolet (https://github.com/cjnolet)

URL: #531
  • Loading branch information
ChuckHastings authored Feb 27, 2022
1 parent 97c3b2b commit 390cf72
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cpp/include/raft/lap/detail/lap_functions.cuh
Original file line number Diff line number Diff line change
Expand Up @@ -466,7 +466,7 @@ inline void dualUpdate(raft::handle_t const& handle,
dim3 threads_per_block;
int total_blocks;

rmm::device_scalar<weight_t> sp_min_v(handle.get_stream());
rmm::device_uvector<weight_t> sp_min_v(SP, handle.get_stream());

raft::lap::detail::calculateLinearDims(blocks_per_grid, threads_per_block, total_blocks, SP);
kernel_dualUpdate_1<<<blocks_per_grid, threads_per_block, 0, handle.get_stream()>>>(
Expand Down

0 comments on commit 390cf72

Please sign in to comment.