Skip to content
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

Fix split_into_nhot() when applied to a view #1509

Merged
merged 1 commit into from
Dec 28, 2018
Merged

Fix split_into_nhot() when applied to a view #1509

merged 1 commit into from
Dec 28, 2018

Conversation

st-pasha
Copy link
Contributor

Function dt.split_into_nhot(frame) now works correctly when frame is a view.

Closes #1507

@st-pasha st-pasha self-assigned this Dec 28, 2018

def test_split_into_nhot_view():
f0 = dt.Frame(A=["cat,dog,mouse", "mouse", None, "dog, cat"])
f1 = dt.split_into_nhot(f0[::-1, :])
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does f0[::-1, :] mean all the rows taken in a reverse order?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, same rules as with a regular python array

@st-pasha st-pasha merged commit e41b739 into master Dec 28, 2018
@st-pasha st-pasha deleted the issue1507 branch December 28, 2018 10:02
@st-pasha st-pasha added this to the Release 0.8.0 milestone Jan 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

split_into_nhot() doesn't work properly on views
2 participants