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.load tolerates FileNotFound fault #6083

Merged
merged 7 commits into from
Aug 27, 2021

Conversation

daquexian
Copy link
Contributor

flow.load(path) 的 path 里如果有多余文件时不报错,并更新相应的单测

Signed-off-by: daquexian <daquexian566@gmail.com>
try:
var_dict[f] = _LoadSingleVariable(var_dir, consistent_src_rank)
except FileNotFoundError:
pass
Copy link
Contributor

Choose a reason for hiding this comment

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

这里是不是要提示用户一句?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

可以的

Signed-off-by: daquexian <daquexian566@gmail.com>
@oneflow-ci-bot oneflow-ci-bot requested review from oneflow-ci-bot and removed request for oneflow-ci-bot August 27, 2021 14:36
@oneflow-ci-bot oneflow-ci-bot removed their request for review August 27, 2021 16:30
@oneflow-ci-bot oneflow-ci-bot self-requested a review August 27, 2021 16:30
@oneflow-ci-bot oneflow-ci-bot requested review from oneflow-ci-bot and removed request for oneflow-ci-bot August 27, 2021 17:58
@github-actions
Copy link
Contributor

Speed stats:
GPU Name: GeForce GTX 1080 

OneFlow resnet50 time: 128.3ms (= 6412.6ms / 50, input_shape=[16, 3, 224, 224], backward is enabled)
OneFlow GPU used (rank 0): 0 MiB
PyTorch resnet50 time: 141.8ms (= 7088.5ms / 50, input_shape=[16, 3, 224, 224], backward is enabled)
PyTorch GPU used (rank 0, estimated): 0 MiB
Relative speed: 1.11 (= 141.8ms / 128.3ms)

OneFlow resnet50 time: 74.6ms (= 3728.2ms / 50, input_shape=[8, 3, 224, 224], backward is enabled)
OneFlow GPU used (rank 0): 0 MiB
PyTorch resnet50 time: 86.6ms (= 4329.5ms / 50, input_shape=[8, 3, 224, 224], backward is enabled)
PyTorch GPU used (rank 0, estimated): 0 MiB
Relative speed: 1.16 (= 86.6ms / 74.6ms)

OneFlow resnet50 time: 49.8ms (= 2490.4ms / 50, input_shape=[4, 3, 224, 224], backward is enabled)
OneFlow GPU used (rank 0): 0 MiB
PyTorch resnet50 time: 61.9ms (= 3093.2ms / 50, input_shape=[4, 3, 224, 224], backward is enabled)
PyTorch GPU used (rank 0, estimated): 0 MiB
Relative speed: 1.24 (= 61.9ms / 49.8ms)

OneFlow resnet50 time: 40.0ms (= 2001.1ms / 50, input_shape=[2, 3, 224, 224], backward is enabled)
OneFlow GPU used (rank 0): 0 MiB
PyTorch resnet50 time: 48.6ms (= 2431.4ms / 50, input_shape=[2, 3, 224, 224], backward is enabled)
PyTorch GPU used (rank 0, estimated): 0 MiB
Relative speed: 1.22 (= 48.6ms / 40.0ms)

OneFlow resnet50 time: 43.3ms (= 2163.3ms / 50, input_shape=[1, 3, 224, 224], backward is enabled)
OneFlow GPU used (rank 0): 0 MiB
PyTorch resnet50 time: 43.2ms (= 2162.2ms / 50, input_shape=[1, 3, 224, 224], backward is enabled)
PyTorch GPU used (rank 0, estimated): 0 MiB
Relative speed: 1.00 (= 43.2ms / 43.3ms)

OneFlow resnet50 time: 140.1ms (= 7003.0ms / 50, input_shape=[16, 3, 224, 224], backward is enabled)
OneFlow GPU used (rank 0): 0 MiB
PyTorch resnet50 time: 150.9ms (= 7546.8ms / 50, input_shape=[16, 3, 224, 224], backward is enabled)
PyTorch GPU used (rank 0, estimated): 0 MiB
Relative speed: 1.08 (= 150.9ms / 140.1ms)

OneFlow resnet50 time: 91.3ms (= 4564.2ms / 50, input_shape=[8, 3, 224, 224], backward is enabled)
OneFlow GPU used (rank 0): 0 MiB
PyTorch resnet50 time: 91.4ms (= 4567.8ms / 50, input_shape=[8, 3, 224, 224], backward is enabled)
PyTorch GPU used (rank 0, estimated): 0 MiB
Relative speed: 1.00 (= 91.4ms / 91.3ms)

OneFlow resnet50 time: 66.8ms (= 3338.3ms / 50, input_shape=[4, 3, 224, 224], backward is enabled)
OneFlow GPU used (rank 0): 0 MiB
PyTorch resnet50 time: 58.3ms (= 2914.2ms / 50, input_shape=[4, 3, 224, 224], backward is enabled)
PyTorch GPU used (rank 0, estimated): 0 MiB
Relative speed: 0.87 (= 58.3ms / 66.8ms)

OneFlow resnet50 time: 56.2ms (= 2811.8ms / 50, input_shape=[2, 3, 224, 224], backward is enabled)
OneFlow GPU used (rank 0): 0 MiB
PyTorch resnet50 time: 55.5ms (= 2776.2ms / 50, input_shape=[2, 3, 224, 224], backward is enabled)
PyTorch GPU used (rank 0, estimated): 0 MiB
Relative speed: 0.99 (= 55.5ms / 56.2ms)

OneFlow resnet50 time: 55.9ms (= 2796.8ms / 50, input_shape=[1, 3, 224, 224], backward is enabled)
OneFlow GPU used (rank 0): 0 MiB
PyTorch resnet50 time: 48.2ms (= 2408.9ms / 50, input_shape=[1, 3, 224, 224], backward is enabled)
PyTorch GPU used (rank 0, estimated): 0 MiB
Relative speed: 0.86 (= 48.2ms / 55.9ms)

@oneflow-ci-bot oneflow-ci-bot removed their request for review August 27, 2021 20:39
@oneflow-ci-bot oneflow-ci-bot merged commit fc30930 into master Aug 27, 2021
@oneflow-ci-bot oneflow-ci-bot deleted the flow_load_tolerates_fault branch August 27, 2021 20: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.

None yet

3 participants