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

add RegNet #170

Merged
merged 8 commits into from
Mar 10, 2022
Merged

add RegNet #170

merged 8 commits into from
Mar 10, 2022

Conversation

kaijieshi7
Copy link
Contributor

@kaijieshi7 kaijieshi7 commented Mar 9, 2022

Add RegNet

  • build model
  • update init.py in models
  • convert pretrained weight
  • inference test on imagenet and update model_zoo
  • update docs
  • update readme
  • update changelog
  • pytorch speed comparison

@kaijieshi7

This comment was marked as spam.

@kaijieshi7
Copy link
Contributor Author

OneFlow regnet_y_400mf time: 55.9ms (= 5588.2ms / 100, input_shape=[16, 3, 224, 224])
PyTorch regnet_y_400mf time: 63.7ms (= 6373.9ms / 100, input_shape=[16, 3, 224, 224])
✔️ Relative speed: 1.14 (= 63.7ms / 55.9ms)

OneFlow regnet_y_800mf time: 48.1ms (= 4810.7ms / 100, input_shape=[16, 3, 224, 224])
PyTorch regnet_y_800mf time: 40.5ms (= 4046.9ms / 100, input_shape=[16, 3, 224, 224])
❌ Relative speed: 0.84 (= 40.5ms / 48.1ms)

OneFlow regnet_y_1_6gf time: 79.5ms (= 7949.1ms / 100, input_shape=[16, 3, 224, 224])
PyTorch regnet_y_1_6gf time: 70.8ms (= 7083.4ms / 100, input_shape=[16, 3, 224, 224])
❌ Relative speed: 0.89 (= 70.8ms / 79.5ms)

OneFlow regnet_y_3_2gf time: 82.9ms (= 8291.1ms / 100, input_shape=[16, 3, 224, 224])
PyTorch regnet_y_3_2gf time: 79.5ms (= 7945.0ms / 100, input_shape=[16, 3, 224, 224])
❌ Relative speed: 0.96 (= 79.5ms / 82.9ms)

OneFlow regnet_y_8gf time: 135.6ms (= 13556.5ms / 100, input_shape=[16, 3, 224, 224])
PyTorch regnet_y_8gf time: 136.5ms (= 13647.1ms / 100, input_shape=[16, 3, 224, 224])
✔️ Relative speed: 1.01 (= 136.5ms / 135.6ms)

OneFlow regnet_y_16gf time: 203.7ms (= 20367.8ms / 100, input_shape=[16, 3, 224, 224])
PyTorch regnet_y_16gf time: 204.1ms (= 20412.9ms / 100, input_shape=[16, 3, 224, 224])
❌ Relative speed: 1.00 (= 204.1ms / 203.7ms)

OneFlow regnet_y_32gf time: 339.5ms (= 33946.6ms / 100, input_shape=[16, 3, 224, 224])
PyTorch regnet_y_32gf time: 341.6ms (= 34159.0ms / 100, input_shape=[16, 3, 224, 224])
✔️ Relative speed: 1.01 (= 341.6ms / 339.5ms)

OneFlow regnet_x_400mf time: 43.2ms (= 4320.2ms / 100, input_shape=[16, 3, 224, 224])
PyTorch regnet_x_400mf time: 50.7ms (= 5073.4ms / 100, input_shape=[16, 3, 224, 224])
✔️ Relative speed: 1.17 (= 50.7ms / 43.2ms)

OneFlow regnet_x_800mf time: 45.4ms (= 4539.3ms / 100, input_shape=[16, 3, 224, 224])
PyTorch regnet_x_800mf time: 42.7ms (= 4270.2ms / 100, input_shape=[16, 3, 224, 224])
❌ Relative speed: 0.94 (= 42.7ms / 45.4ms)

OneFlow regnet_x_1_6gf time: 49.7ms (= 4971.6ms / 100, input_shape=[16, 3, 224, 224])
PyTorch regnet_x_1_6gf time: 47.2ms (= 4723.0ms / 100, input_shape=[16, 3, 224, 224])
❌ Relative speed: 0.95 (= 47.2ms / 49.7ms)

OneFlow regnet_x_3_2gf time: 79.5ms (= 7945.4ms / 100, input_shape=[16, 3, 224, 224])
PyTorch regnet_x_3_2gf time: 67.9ms (= 6788.5ms / 100, input_shape=[16, 3, 224, 224])
❌ Relative speed: 0.85 (= 67.9ms / 79.5ms)

OneFlow regnet_x_8gf time: 100.5ms (= 10050.5ms / 100, input_shape=[16, 3, 224, 224])
PyTorch regnet_x_8gf time: 101.1ms (= 10109.9ms / 100, input_shape=[16, 3, 224, 224])
✔️ Relative speed: 1.01 (= 101.1ms / 100.5ms)

OneFlow regnet_x_16gf time: 176.5ms (= 17653.7ms / 100, input_shape=[16, 3, 224, 224])
PyTorch regnet_x_16gf time: 177.4ms (= 17740.6ms / 100, input_shape=[16, 3, 224, 224])
❌ Relative speed: 1.00 (= 177.4ms / 176.5ms)

OneFlow regnet_x_32gf time: 335.5ms (= 33548.6ms / 100, input_shape=[16, 3, 224, 224])
PyTorch regnet_x_32gf time: 334.9ms (= 33491.0ms / 100, input_shape=[16, 3, 224, 224])
❌ Relative speed: 1.00 (= 334.9ms / 335.5ms)

OneFlow regnet_y_400mf time: 12.4ms (= 1241.6ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
PyTorch regnet_y_400mf time: 12.7ms (= 1269.4ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
✔️ Relative speed: 1.02 (= 12.7ms / 12.4ms)


Setting OMP_NUM_THREADS environment variable for each process to be 1 in default, to avoid your system being overloaded, please further tune the variable for optimal performance in your application as needed.


OneFlow regnet_y_800mf time: 12.7ms (= 1266.3ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
PyTorch regnet_y_800mf time: 9.7ms (= 972.4ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
❌ Relative speed: 0.77 (= 9.7ms / 12.7ms)


Setting OMP_NUM_THREADS environment variable for each process to be 1 in default, to avoid your system being overloaded, please further tune the variable for optimal performance in your application as needed.


OneFlow regnet_y_1_6gf time: 19.9ms (= 1990.5ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
PyTorch regnet_y_1_6gf time: 16.4ms (= 1643.8ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
❌ Relative speed: 0.83 (= 16.4ms / 19.9ms)


Setting OMP_NUM_THREADS environment variable for each process to be 1 in default, to avoid your system being overloaded, please further tune the variable for optimal performance in your application as needed.


OneFlow regnet_y_3_2gf time: 25.1ms (= 2505.8ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
PyTorch regnet_y_3_2gf time: 21.6ms (= 2164.3ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
❌ Relative speed: 0.86 (= 21.6ms / 25.1ms)


Setting OMP_NUM_THREADS environment variable for each process to be 1 in default, to avoid your system being overloaded, please further tune the variable for optimal performance in your application as needed.


OneFlow regnet_y_8gf time: 45.0ms (= 4496.5ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
PyTorch regnet_y_8gf time: 41.3ms (= 4133.2ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
❌ Relative speed: 0.92 (= 41.3ms / 45.0ms)


Setting OMP_NUM_THREADS environment variable for each process to be 1 in default, to avoid your system being overloaded, please further tune the variable for optimal performance in your application as needed.


OneFlow regnet_y_16gf time: 67.8ms (= 6781.8ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
PyTorch regnet_y_16gf time: 63.5ms (= 6351.3ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
❌ Relative speed: 0.94 (= 63.5ms / 67.8ms)


Setting OMP_NUM_THREADS environment variable for each process to be 1 in default, to avoid your system being overloaded, please further tune the variable for optimal performance in your application as needed.


OneFlow regnet_y_32gf time: 126.5ms (= 12647.5ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
PyTorch regnet_y_32gf time: 107.4ms (= 10735.3ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
❌ Relative speed: 0.85 (= 107.4ms / 126.5ms)


Setting OMP_NUM_THREADS environment variable for each process to be 1 in default, to avoid your system being overloaded, please further tune the variable for optimal performance in your application as needed.


OneFlow regnet_x_400mf time: 12.1ms (= 1210.6ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
PyTorch regnet_x_400mf time: 12.8ms (= 1284.8ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
✔️ Relative speed: 1.06 (= 12.8ms / 12.1ms)


Setting OMP_NUM_THREADS environment variable for each process to be 1 in default, to avoid your system being overloaded, please further tune the variable for optimal performance in your application as needed.


OneFlow regnet_x_800mf time: 11.0ms (= 1104.6ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
PyTorch regnet_x_800mf time: 9.2ms (= 920.1ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
❌ Relative speed: 0.83 (= 9.2ms / 11.0ms)


Setting OMP_NUM_THREADS environment variable for each process to be 1 in default, to avoid your system being overloaded, please further tune the variable for optimal performance in your application as needed.


OneFlow regnet_x_1_6gf time: 15.6ms (= 1561.6ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
PyTorch regnet_x_1_6gf time: 12.2ms (= 1220.7ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
❌ Relative speed: 0.78 (= 12.2ms / 15.6ms)


Setting OMP_NUM_THREADS environment variable for each process to be 1 in default, to avoid your system being overloaded, please further tune the variable for optimal performance in your application as needed.


OneFlow regnet_x_3_2gf time: 23.1ms (= 2310.5ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
PyTorch regnet_x_3_2gf time: 19.3ms (= 1933.2ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
❌ Relative speed: 0.84 (= 19.3ms / 23.1ms)


Setting OMP_NUM_THREADS environment variable for each process to be 1 in default, to avoid your system being overloaded, please further tune the variable for optimal performance in your application as needed.


OneFlow regnet_x_8gf time: 35.1ms (= 3511.6ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
PyTorch regnet_x_8gf time: 31.7ms (= 3168.2ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
❌ Relative speed: 0.90 (= 31.7ms / 35.1ms)


Setting OMP_NUM_THREADS environment variable for each process to be 1 in default, to avoid your system being overloaded, please further tune the variable for optimal performance in your application as needed.


OneFlow regnet_x_16gf time: 62.8ms (= 6279.9ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
PyTorch regnet_x_16gf time: 57.1ms (= 5712.4ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
❌ Relative speed: 0.91 (= 57.1ms / 62.8ms)


Setting OMP_NUM_THREADS environment variable for each process to be 1 in default, to avoid your system being overloaded, please further tune the variable for optimal performance in your application as needed.


OneFlow regnet_x_32gf time: 110.3ms (= 11029.4ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
PyTorch regnet_x_32gf time: 105.3ms (= 10529.6ms / 100, input_shape=[16, 3, 224, 224], backward is disabled, ddp, world size=2)
❌ Relative speed: 0.95 (= 105.3ms / 110.3ms)


Setting OMP_NUM_THREADS environment variable for each process to be 1 in default, to avoid your system being overloaded, please further tune the variable for optimal performance in your application as needed.


@rentainhe rentainhe merged commit d239317 into main Mar 10, 2022
@rentainhe rentainhe deleted the regnet_skj_new branch March 10, 2022 07:06
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.

2 participants