"...git@developer.sourcefind.cn:renzhc/diffusers_dcu.git" did not exist on "67533c798ca95172d7b9999dd28d9d6e57a67432"
Commit fbe34dd4 authored by ltqin's avatar ltqin
Browse files

fix offset name

parent da1afd7f
......@@ -52,11 +52,14 @@ struct MaskUpperTriangleFromTopLeftPredicate
};
struct MaskUpperTriangleFromBottomRightPredicate
{
MaskUpperTriangleFromBottomRightPredicate() : offset_(0) {}
__host__ __device__ void SetOffset(const index_t offset) { offset_ = offset; }
MaskUpperTriangleFromBottomRightPredicate() : diagonal_offset_(0) {}
__host__ __device__ void SetDiagonalOffset(const index_t diagonal_offset)
{
diagonal_offset_ = diagonal_offset;
}
__host__ __device__ constexpr bool operator()(index_t m, index_t n) const
{
return n > (m + offset_);
return n > (m + diagonal_offset_);
}
__host__ __device__ constexpr bool
......@@ -66,7 +69,7 @@ struct MaskUpperTriangleFromBottomRightPredicate
}
private:
index_t offset_;
index_t diagonal_offset_;
};
// to track the points which need to be set to -inf on C0
......@@ -80,7 +83,7 @@ struct C0MatrixMask_impl
MaskUpperTriangleFromBottomRightPredicate>::value)
{
if(NRaw > MRaw)
predicate_.SetOffset(NRaw - MRaw);
predicate_.SetDiagonalOffset(NRaw - MRaw);
}
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment