-
Notifications
You must be signed in to change notification settings - Fork 5.7k
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
Exposing Channel to be used as a Variable and integrating with Fluid #8486
Merged
Merged
Changes from 34 commits
Commits
Show all changes
35 commits
Select commit
Hold shift + click to select a range
0db0632
Adding set_capacity method support
3451c4e
Adding Python for make_channel
fcd086a
Updating notest_concurrency
25674f0
Write python for make_channel method
a393b4e
Write python for make_channel method
2f612da
Fix make_channel and test
68d5977
Placeholder ops for channel send, recv and close
e73d30f
Adding ToTypeIndex method to var_type.h
267c3ad
Add var_type.h to channel:
b499d8d
Added POD_Type to the method
f6803e7
Add CHANNEL to executor
53d82aa
Updated get and set DataType to accomodate Channels
029337f
Updating get and set to incorporate channels
6a100a7
Adding CHANNEL as supported VarType in protobuf
64cc34d
Removing unecessary import
d87a65d
Fixing VarDesc to adapt to Channel as VarType
f3d6a2d
Add channel.h to executor
20817bd
Remove innclude from channel
52a96aa
Updated var_type to support Channel as var type
6a01d3e
Adding get_channel to pybind
4022dcc
Added ChannelHolder
dfea686
Adding make_channel as an op
1c0f569
Adding ChannelHolder in channel
9fa0ca9
Merge branch 'channel_cpp' into refine_channel
abhinavarora 210f0be
Merge pull request #1 from abhinavarora/refine_channel
abhinavarora e99f230
Fixing merge conflict
f33031b
Fixing typo
b3a53b1
Merge branch 'channel_cpp' of github.com:abhinavarora/Paddle into cha…
a79de61
Commenting out operators in concurrency
255cd0b
Merge branch 'channel_cpp' of https://github.com/abhinavarora/Paddle …
7d648b8
Removing totypeid right now since we don't need it.
5206574
Reverting python changes
150db1b
Fixing typo in framework.py
d4d493d
Modify comments for ReaderHolder
6e37b8b
Merge remote-tracking branch 'origin/develop' into channel_cpp
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
It looks to me that it might be possible to remove the current base class
Channel
fromchannel.h
, and renameChannelHolder
intoChannel
, if we write hereI am not an expert of
boost::variant
, but I see it is used many places in our codebase. For example:Paddle/paddle/fluid/platform/place.h
Line 53 in 24509f4
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 verified that we could use the polymorphism provided by boost::variant to call Send:
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.
Thank you @wangkuiyi . This looks interesting. I'll look into this Visitor pattern polymorphism.
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.
Extend the above example to work with unique_ptr: