Skip to content

Commit

Permalink
[CUDA] Fix BeamSearchTest.DummyT5WithSequenceInputIds test failure in…
Browse files Browse the repository at this point in the history
… Windows (#23596)

### Description
BeamSearchTest.DummyT5WithSequenceInputIds failed in Windows due to
early stopping triggered. The cause is state.early_stopping_ is
interpreted as true in cuda kernel at some point, however printf still
show its value is false. The root cause is unknown.

Update the code to use early_stopping as template parameter seems walk
around the issue.

Other changes: 
* Add some debug code (will not be built into binary unless
DEBUG_GENERATION is fined) to assist debugging beam search scorer in
CUDA.
* Enable DummyT5WithSequenceInputIds test in CI. This test was not run
in Windows CUDA CI pipeline previously.

### Motivation and Context

Fix a unit test BeamSearchTest.DummyT5WithSequenceInputIds failure in
Windows.
  • Loading branch information
tianleiwu authored Feb 6, 2025
1 parent d981b15 commit 2c2ff4a
Show file tree
Hide file tree
Showing 4 changed files with 181 additions and 90 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
#include <gsl/gsl>
#include "core/framework/allocator.h"
#include "core/framework/ort_value.h"
#include "contrib_ops/cpu/utils/debug_macros.h"
#include "contrib_ops/cpu/utils/console_dumper.h"

namespace onnxruntime {

Expand Down
Loading

0 comments on commit 2c2ff4a

Please sign in to comment.