Skip to content
This repository has been archived by the owner on Nov 17, 2023. It is now read-only.

Crop assign #3547

Merged
merged 7 commits into from
Oct 18, 2016
Merged

Crop assign #3547

merged 7 commits into from
Oct 18, 2016

Conversation

pluskid
Copy link
Contributor

@pluskid pluskid commented Oct 17, 2016

Depends on dmlc/mshadow#172

Added a _crop_assign op to replace legacy _copy_slice_to and _assign_slice_from operators.

I did not expose this to __setitem__ and __getitem__ as this will make copy, while our existing get item functions shares memory.

@piiswrong

@piiswrong
Copy link
Contributor

This can be safely exposed to setitem and return None to disable chain assign.
we can discuss how to do it for getitem later. My opinion is it should return a copy that's marked as read only

@pluskid
Copy link
Contributor Author

pluskid commented Oct 17, 2016

Exposed __setitem__

@pluskid pluskid merged commit cf00ca0 into apache:master Oct 18, 2016
@pluskid pluskid deleted the crop_assign branch October 18, 2016 00:36
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants