Skip to content

Commit

Permalink
Fixed sign comparison error
Browse files Browse the repository at this point in the history
  • Loading branch information
MarkBicknellONT committed Jun 3, 2024
1 parent 03d94f3 commit 1d389d0
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions dorado/read_pipeline/ScalerNode.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,8 @@ void ScalerNode::input_thread_fn() {
int trim_start = 0;
if (is_rna_model) {
trim_start = determine_rna_adapter_pos(*read, m_model_type);
if (m_trim_rna_adapter && trim_start < read->read_common.get_raw_data_samples()) {
if (m_trim_rna_adapter &&
size_t(trim_start) < read->read_common.get_raw_data_samples()) {
read->read_common.raw_data =
read->read_common.raw_data.index({Slice(trim_start, at::indexing::None)});
read->read_common.rna_adapter_end_signal_pos = 0;
Expand Down Expand Up @@ -241,7 +242,7 @@ void ScalerNode::input_thread_fn() {
utils::DEFAULT_TRIM_MIN_ELEMENTS);
}

if (trim_start < read->read_common.get_raw_data_samples()) {
if (size_t(trim_start) < read->read_common.get_raw_data_samples()) {
read->read_common.raw_data =
read->read_common.raw_data.index({Slice(trim_start, at::indexing::None)});
} else {
Expand Down

0 comments on commit 1d389d0

Please sign in to comment.