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

flow.S/B/P #5306

Merged
merged 39 commits into from
Jul 7, 2021
Merged

flow.S/B/P #5306

merged 39 commits into from
Jul 7, 2021

Conversation

clackhan
Copy link
Contributor

@clackhan clackhan commented Jun 24, 2021

>>> import oneflow as flow
>>> b = flow.sbp.broadcast
>>> b
oneflow.sbp.broadcast
>>> type(b)
<class 'oneflow.sbp.sbp'>
>>> p = flow.sbp.partial_sum
>>> p
oneflow.sbp.partial_sum
>>> type(p)
<class 'oneflow.sbp.sbp'>
>>> s0 = flow.sbp.split(0)
>>> s0
oneflow.sbp.split(axis=0)
>>> type(s0)
<class 'oneflow.sbp.sbp'>
>>> d = flow.device("cuda:0")
>>> d
device(type='cuda', index=0)
>>> type(d)
<class 'oneflow.device'>
>>> x = flow.Tensor([1, 2, 3])
>>> x
tensor([1., 2., 3.], dtype=oneflow.float32)
>>> type(x)
<class 'oneflow.Tensor'>

@clackhan clackhan requested a review from oneflow-ci-bot June 24, 2021 11:32
@oneflow-ci-bot oneflow-ci-bot removed their request for review June 24, 2021 12:34
@clackhan clackhan requested a review from oneflow-ci-bot June 25, 2021 01:53
oneflow/init.py Outdated Show resolved Hide resolved
oneflow/init.py Outdated Show resolved Hide resolved
oneflow/init.py Outdated Show resolved Hide resolved
oneflow/init.py Outdated Show resolved Hide resolved
@clackhan clackhan requested review from oneflow-ci-bot and removed request for oneflow-ci-bot June 25, 2021 11:00
std::shared_ptr<std::vector<std::shared_ptr<cfg::SbpParallel>>> ret =
std::make_shared<std::vector<std::shared_ptr<cfg::SbpParallel>>>(max_split_axis);
std::string SbpParallelSymbolToString(const Symbol<cfg::SbpParallel>& sbp_sym) {
std::string sbp_str = "sbp(type='";
Copy link
Contributor Author

Choose a reason for hiding this comment

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

@guo-ran
Copy link
Contributor

guo-ran commented Jun 25, 2021

规定成这样,是确定未来不会有其他Partial了吗,比如partial max

@clackhan clackhan requested a review from oneflow-ci-bot July 5, 2021 09:30
@oneflow-ci-bot oneflow-ci-bot requested review from oneflow-ci-bot and removed request for oneflow-ci-bot July 5, 2021 10:03
@oneflow-ci-bot oneflow-ci-bot requested review from oneflow-ci-bot and removed request for oneflow-ci-bot July 5, 2021 11:04
@oneflow-ci-bot oneflow-ci-bot requested review from oneflow-ci-bot and removed request for oneflow-ci-bot July 5, 2021 12:34
clackhan added 3 commits July 6, 2021 16:10
* add_new_placement_init_func

* flow.env.all_device_placement

* refine

* refine

* refine

* refine

* refine

* refine
@clackhan clackhan requested a review from oneflow-ci-bot July 7, 2021 01:30
@clackhan clackhan requested review from oneflow-ci-bot and removed request for oneflow-ci-bot July 7, 2021 01:37
@clackhan clackhan requested review from oneflow-ci-bot and removed request for oneflow-ci-bot July 7, 2021 02:07
@clackhan clackhan requested review from oneflow-ci-bot and removed request for oneflow-ci-bot July 7, 2021 02:39
@oneflow-ci-bot oneflow-ci-bot merged commit 00f1230 into master Jul 7, 2021
@oneflow-ci-bot oneflow-ci-bot deleted the flow.S/B/P branch July 7, 2021 03:40
@oneflow-ci-bot oneflow-ci-bot removed their request for review July 7, 2021 03:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants