-
Notifications
You must be signed in to change notification settings - Fork 0
hotfix / include ptrMatrices in matrix-axis slices #51
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
When slicing, m_d_ptrMatrices should be nullptr unless nMats>1
@@ -659,10 +661,6 @@ DTensor<T>::DTensor(const DTensor<T> &other, size_t axis, size_t from, size_t to | |||
m_d_data = other.m_d_data + offset; | |||
m_doDestroyData = false; | |||
m_doDestroyPtrMatrices = false; | |||
if (axis != 2) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I removed this because I put m_d_ptrMatrices = nullptr;
at the beginning.
if (axis == 2) { | ||
offset = other.m_numRows * other.m_numCols * from; | ||
m_numRows = other.m_numRows; | ||
m_numCols = other.m_numCols; | ||
m_numMats = len; | ||
m_d_ptrMatrices = other.m_d_ptrMatrices + from; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line should be here (inside if (axis == 2)
)
Get rid of warning in DTensor<T>::createRandomTensor ci/script: use pushd/popd instead of cd update CHANGELOG
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@ruairimoran I made a couple of changes - we can merge if you're happy with them.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
Make sure ptrMatrices is included when slicing on matrix axis