Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

config.yml 47 KB

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
  1. version: 2.1
  2. parameters:
  3. ad_hoc_container_build:
  4. type: boolean
  5. default: false
  6. ad_hoc_container_build_code_only:
  7. type: boolean
  8. default: false
  9. remote_docker_version:
  10. type: string
  11. description: remote docker version
  12. default: "20.10.18"
  13. sg_docker_version:
  14. type: string
  15. description: the version of super gradients docker image
  16. default: "2.0.0"
  17. build_py_version:
  18. type: string
  19. description: Python version
  20. default: "3.8"
  21. run_sanity_tests_flow:
  22. type: boolean
  23. description: If true will run sanity_test flow
  24. default: false
  25. skip_md_files:
  26. type: boolean
  27. default: true
  28. orb_version:
  29. type: string
  30. description: Deci ai ORB version https://circleci.com/developer/orbs/orb/deci-ai/circleci-common-orb
  31. default: "10.5.1"
  32. # default: "dev:alpha"
  33. orbs:
  34. deci-common: deci-ai/circleci-common-orb@<< pipeline.parameters.orb_version >>
  35. aws-ecr: circleci/aws-ecr@8.2.1
  36. docker: circleci/docker@2.2.0
  37. slack: circleci/slack@4.12.0 # see https://circleci.com/developer/orbs/orb/circleci/slack for examples and more
  38. # This filter operates on SemVer2 tags only
  39. release_tag_filter: &release_tag_filter
  40. filters:
  41. branches:
  42. ignore: /.*/
  43. tags:
  44. only: /^\d+\.\d+\.\d+$/
  45. release_candidate_filter: &release_candidate_filter
  46. filters:
  47. branches:
  48. only: master
  49. release_candidate_tag_filter: &release_candidate_tag_filter
  50. filters:
  51. branches:
  52. ignore: /.*/
  53. tags:
  54. only: /^\d+\.\d+\.\d+rc\d+/
  55. commands:
  56. build_and_publish_command:
  57. parameters:
  58. repo_name:
  59. type: string
  60. docker_context:
  61. type: string
  62. image_tag:
  63. type: string
  64. additional_tags:
  65. type: string
  66. build_args:
  67. type: string
  68. default: ""
  69. dockerfile:
  70. type: string
  71. default: "Dockerfile"
  72. steps:
  73. - checkout
  74. - attach_workspace:
  75. at: ~/
  76. - run:
  77. name: Put config dir in repo context
  78. command: |
  79. if [ -d ~/.config ]; then
  80. echo "found a .config directory, copying to repo dir"
  81. cp -r ~/.config ~/project/<< parameters.docker_context >>
  82. fi
  83. - deci-common/ecr_login_dev
  84. - deci-common/container_image_build:
  85. context: << parameters.docker_context >>
  86. working_directory: "."
  87. repository_name: << parameters.repo_name >>
  88. image_tag: << parameters.image_tag >>
  89. dockerfile: << parameters.dockerfile >>
  90. build_args: << parameters.build_args >>
  91. # build_args: "PYTHON_VERSION=3.8 SG_VERSION=3.0.7"
  92. - deci-common/push_docker_image_aws_dev:
  93. repository_name: << parameters.repo_name >>
  94. image_tag: << parameters.image_tag >>
  95. additional_tags: << parameters.additional_tags >>
  96. get_beta_and_rc_tags:
  97. description: "getting beta and rc tag (if exist) according to ouir convention"
  98. steps:
  99. - attach_workspace:
  100. at: ~/
  101. - run:
  102. name: push BETA_TAG and RC_TAG variable to BASH_ENV
  103. command: |
  104. if [[ -f ~/BETA_TAG ]]; then
  105. echo 'export BETA_TAG="$(cat ~/BETA_TAG)"' >> "$BASH_ENV"
  106. source $BASH_ENV
  107. fi
  108. if [[ -f ~/RC_TAG ]]; then
  109. echo 'export RC_TAG="$(cat ~/RC_TAG)"' >> "$BASH_ENV"
  110. source $BASH_ENV
  111. fi
  112. echo "RC_TAG=$RC_TAG || BETA_TAG=$BETA_TAG"
  113. adding_tag_to_ecr_container_image:
  114. description: adding a tag to an existing container image
  115. parameters:
  116. image_repo:
  117. type: string
  118. new_image_tag:
  119. type: string
  120. source_image_tag:
  121. type: string
  122. steps:
  123. - deci-common/run_on_dev_account:
  124. command: |
  125. MANIFEST=$(aws ecr batch-get-image --repository-name << parameters.image_repo >> --image-ids imageTag=<< parameters.source_image_tag >> --query 'images[].imageManifest' --output text)
  126. aws ecr put-image --repository-name << parameters.image_repo >> --image-tag << parameters.new_image_tag >> --image-manifest "$MANIFEST"
  127. echo "added tag: << parameters.new_image_tag >> to image: << parameters.image_repo >>:<< parameters.new_image_tag >>"
  128. jobs:
  129. build:
  130. environment:
  131. CIRCLE_COMPARE_URL: << pipeline.project.git_url >>/compare/<< pipeline.git.base_revision >>..<<pipeline.git.revision>>
  132. parameters:
  133. py_version:
  134. type: string
  135. default: latest
  136. package_name:
  137. type: string
  138. docker:
  139. - image: cimg/python:<< parameters.py_version >>
  140. resource_class: large
  141. steps:
  142. - deci-common/checkout_and_skip_build:
  143. check_version_file: true
  144. skip_md_files: << pipeline.parameters.skip_md_files >>
  145. - deci-common/get_persisted_version_info
  146. - unless:
  147. condition:
  148. equal: [ master, << pipeline.git.branch >> ]
  149. steps:
  150. - run:
  151. name: install Black Flake8 python linter
  152. command: |
  153. pip install --user -r requirements.dev.txt
  154. - run:
  155. name: Lint all python files changed since develop branch
  156. command: |
  157. flake8 --statistics --config scripts/flake8-config setup.py $(git diff --diff-filter ACM origin/master --name-only | grep 'py$' | grep -v 'experimental/' | grep -v 'experimental_models/')
  158. - run:
  159. name: Run Black on changed files against master branch
  160. command: |
  161. black --check setup.py $(git diff --diff-filter ACM origin/master --name-only | grep 'py$' | grep -v 'experimental/' | grep -v 'experimental_models/')
  162. - run:
  163. name: add requirements.txt and requirements.pro.txt to source code
  164. command: |
  165. cp requirements.txt src/super_gradients/requirements.txt
  166. cp requirements.pro.txt src/super_gradients/requirements.pro.txt
  167. - run:
  168. name: install python dependencies
  169. command: |
  170. python3 -m venv venv
  171. . venv/bin/activate
  172. python3 -m pip install pip==23.1.2
  173. python3 -m pip install -r requirements.txt
  174. - run:
  175. name: edit package version
  176. command: |
  177. echo "${NEW_VERSION}" > version.txt
  178. cat version.txt
  179. - run:
  180. name: setup custom environment variables
  181. command: |
  182. echo 'export UPLOAD_LOGS=FALSE' >> $BASH_ENV
  183. - run:
  184. name: install package
  185. no_output_timeout: 30m
  186. command: |
  187. . venv/bin/activate
  188. python3 -m pip uninstall -y super_gradients
  189. python3 -m pip install -e .[pro] --extra-index-url https://pypi.ngc.nvidia.com
  190. - run:
  191. name: install pytorch quantization package
  192. no_output_timeout: 30m
  193. command: |
  194. . venv/bin/activate
  195. python3 -m pip install pytorch-quantization==2.1.2 --extra-index-url https://pypi.ngc.nvidia.com
  196. python3 -m pip install onnx_graphsurgeon==0.3.27 --extra-index-url https://pypi.ngc.nvidia.com
  197. - run:
  198. name: run tests with coverage
  199. no_output_timeout: 30m
  200. command: |
  201. . venv/bin/activate
  202. coverage run --source=super_gradients -m unittest tests/deci_core_unit_test_suite_runner.py
  203. coverage report
  204. coverage html # open htmlcov/index.html in a browser
  205. - store_artifacts:
  206. path: htmlcov
  207. - store_artifacts:
  208. path: ~/sg_logs
  209. change_rc_to_b:
  210. description: "change rc in the tag to b"
  211. docker:
  212. - image: cimg/base:stable-20.04
  213. resource_class: small
  214. steps:
  215. - run:
  216. name: change the rc to b
  217. command:
  218. |
  219. BETA_TAG=$(echo ${CIRCLE_TAG} | sed -e 's|rc|b|'); echo ${BETA_TAG} >> ~/BETA_TAG
  220. cat ~/BETA_TAG
  221. - persist_to_workspace:
  222. root: ~/
  223. paths:
  224. - "BETA_TAG"
  225. build_and_publish_sg_container:
  226. description : "building the temp image and pushing to dev ecr"
  227. parameters:
  228. repo_name:
  229. type: string
  230. default: 'deci/super-gradients'
  231. sg_python_version:
  232. type: string
  233. default: $CIRCLE_TAG
  234. docker:
  235. - image: cimg/base:stable-20.04
  236. resource_class: small
  237. steps:
  238. - checkout
  239. - get_beta_and_rc_tags
  240. - run:
  241. command: echo *$BETA_TAG*
  242. - setup_remote_docker:
  243. version: << pipeline.parameters.remote_docker_version >>
  244. docker_layer_caching: true
  245. - deci-common/container_image_build:
  246. dockerfile: scripts/Dockerfile
  247. repository_name: << parameters.repo_name >>
  248. image_tag: "$BETA_TAG"
  249. build_args: 'SG_VERSION=<< parameters.sg_python_version >>'
  250. extra_flags: ' --compress'
  251. - deci-common/push_docker_image_aws_dev:
  252. repository_name: << parameters.repo_name >>
  253. image_tag: "$BETA_TAG"
  254. additional_tags: "latest"
  255. find_rc_tag_per_sha:
  256. description: this command will take the sha of the last commit and find the rc tag it belongs to as ${RC_TAG} variale
  257. docker:
  258. - image: cimg/aws:2022.11.1
  259. resource_class: small
  260. steps:
  261. - checkout
  262. - run:
  263. name: get rc tag of the final tag
  264. command: |
  265. if [[ $(RC_TAG=$(git tag --contains ${CIRCLE_SHA1} | grep -E '[[:digit:]]+\.[[:digit:]]+\.[[:digit:]]+rc[[:digit:]]+' | head -n 1)) ]] ; then
  266. echo "Found RC version: ${RC_TAG}"
  267. echo $RC_TAG >> ~/RC_TAG
  268. else
  269. echo "No Rc Tag found for commit"
  270. circleci-agent step halt
  271. fi
  272. - persist_to_workspace:
  273. root: ~/
  274. paths:
  275. - "RC_TAG"
  276. add_rc_tag_to_beta:
  277. description: in the event of successful test promote beta to rc
  278. parameters:
  279. image_repo:
  280. type: string
  281. default: "deci/super-gradients"
  282. docker:
  283. - image: cimg/base:stable-20.04
  284. resource_class: small
  285. steps:
  286. - get_beta_and_rc_tags
  287. - run:
  288. command: |
  289. echo $BETA_TAG
  290. - adding_tag_to_ecr_container_image:
  291. image_repo: << parameters.image_repo >>
  292. source_image_tag: $BETA_TAG
  293. new_image_tag: $CIRCLE_TAG
  294. add_release_tag_to_rc:
  295. description: in the event of successful test promote rc to release and latest
  296. parameters:
  297. image_repo:
  298. type: string
  299. default: "deci/super-gradients"
  300. docker:
  301. - image: cimg/base:stable-20.04
  302. resource_class: small
  303. steps:
  304. - get_beta_and_rc_tags
  305. - run:
  306. command: |
  307. if [ -z $RC_TAG ] ; then
  308. circleci-agent step halt
  309. else
  310. echo $RC_TAG
  311. fi
  312. - adding_tag_to_ecr_container_image:
  313. image_repo: << parameters.image_repo >>
  314. source_image_tag: $RC_TAG
  315. new_image_tag: ${CIRCLE_TAG}
  316. testing_supergradients_docker_image:
  317. description: "running integration test on the code"
  318. parameters:
  319. image_repo:
  320. type: string
  321. #reserved for testing when will be done
  322. #machine: true
  323. #resource_class: deci-ai/research-standard
  324. docker:
  325. - image: cimg/base:stable-20.04
  326. steps:
  327. - deci-common/ecr_login_dev
  328. - get_beta_and_rc_tags
  329. # - run:
  330. # name: integration test
  331. # #command: sudo docker run -it -e ENVIRONMENT_NAME=production -v ${PWD}:/SG -v /data:/data deciai/super-gradients:3.0.0 python3 ./tests/integration_tests/pretrained_models_test.py
  332. # command: docker run --rm -it --shm-size=2gb --gpus all -v ${PWD}:/SG -v /data:/data << parameters.image_repo >>:<< parameters.image_tag >> python3 -c 'print("it works!")'
  333. - run:
  334. command: echo Hello world
  335. release_candidate:
  336. environment:
  337. CIRCLE_COMPARE_URL: << pipeline.project.git_url >>/compare/<< pipeline.git.base_revision >>..<<pipeline.git.revision>>
  338. parameters:
  339. py_version:
  340. type: string
  341. docker:
  342. - image: cimg/python:<< parameters.py_version >>
  343. steps:
  344. - deci-common/checkout_and_skip_build:
  345. check_version_file: true
  346. skip_md_files: true
  347. - deci-common/get_persisted_version_info
  348. - run:
  349. name: edit package version
  350. command: |
  351. echo $NEW_VERSION > version.txt
  352. - deci-common/pip_upload_package_codeartifact_dev:
  353. codeartifact_repository: "deci-packages"
  354. - deci-common/pip_test_package_installation_codeartifact_dev:
  355. package_name: "super-gradients"
  356. version: $NEW_VERSION
  357. - deci-common/git_config_automation_user
  358. - run:
  359. name: "commit version file"
  360. command: |
  361. git commit version.txt -m "Deci Services - Changed version to $NEW_VERSION"
  362. - deci-common/git_commit_and_tag:
  363. version: $NEW_VERSION
  364. release_version:
  365. environment:
  366. CIRCLE_COMPARE_URL: << pipeline.project.git_url >>/compare/<< pipeline.git.base_revision >>..<<pipeline.git.revision>>
  367. parameters:
  368. py_version:
  369. type: string
  370. dev_venv_name:
  371. type: string
  372. default: "dev-sg-${CIRCLE_BUILD_NUM}"
  373. docker:
  374. - image: cimg/python:<< parameters.py_version >>
  375. steps:
  376. - deci-common/checkout_and_skip_build:
  377. check_version_file: true
  378. skip_md_files: false
  379. - run:
  380. name: add requirements.txt and requirements.pro.txt to source code
  381. command: |
  382. cp requirements.txt src/super_gradients/requirements.txt
  383. cp requirements.pro.txt src/super_gradients/requirements.pro.txt
  384. - run:
  385. name: edit package version
  386. command: |
  387. echo $CIRCLE_TAG > version.txt
  388. - deci-common/pip_upload_package_codeartifact_all_accounts:
  389. codeartifact_repository: "deci-packages"
  390. - deci-common/pip_test_package_installation_codeartifact_dev:
  391. package_name: "super-gradients"
  392. version: $CIRCLE_TAG
  393. venv_name: << parameters.dev_venv_name >>
  394. - run:
  395. name: verify that the output of __version__ is what we expect
  396. command: |
  397. . << parameters.dev_venv_name >>-super-gradients-$CIRCLE_TAG/bin/activate
  398. python3 tests/verify_version.py $CIRCLE_TAG
  399. - deci-common/pip_test_package_installation_codeartifact_prod:
  400. package_name: "super-gradients"
  401. version: $CIRCLE_TAG
  402. - deci-common/pip_upload_package_codeartifact_prod:
  403. codeartifact_repository: "deci-toolkit"
  404. - deci-common/git_commit_and_tag:
  405. version: $CIRCLE_TAG
  406. delete_remote_tag_before_tagging: true
  407. - deci-common/tag_as:
  408. tag_name: "stable"
  409. delete_remote: true
  410. - deci-common/github_create_release:
  411. github_cli_token: $GITHUB_CLI_TOKEN
  412. directory_to_cd_into: "."
  413. tag: $CIRCLE_TAG
  414. notes: "This GitHub Release was done automatically by CircleCI"
  415. hydra_sweeper_test:
  416. docker:
  417. - image: 307629990626.dkr.ecr.us-east-1.amazonaws.com/deci/infra/circleci/runner/sg-gpu:<< pipeline.parameters.sg_docker_version >>
  418. resource_class: deci-ai/sg-gpu-on-premise
  419. parameters:
  420. sg_existing_env_path:
  421. type: string
  422. default: "/env/persistent_env"
  423. sg_new_env_name:
  424. type: string
  425. default: "${CIRCLE_BUILD_NUM}"
  426. sg_new_env_python_version:
  427. type: string
  428. default: "python3.8"
  429. steps:
  430. - checkout
  431. - run:
  432. name: install requirements and run recipe tests
  433. command: |
  434. << parameters.sg_new_env_python_version >> -m venv << parameters.sg_new_env_name >>
  435. source << parameters.sg_new_env_name >>/bin/activate
  436. python3.8 -m pip install --upgrade setuptools pip wheel
  437. python3.8 -m pip install -r requirements.txt
  438. python3.8 -m pip install .
  439. python3.8 -m pip install torch torchvision torchaudio
  440. make sweeper_test
  441. - run:
  442. name: Remove new environment when failed
  443. command: "rm -r << parameters.sg_new_env_name >>"
  444. when: on_fail
  445. - slack/notify:
  446. channel: "sg-integration-tests"
  447. event: fail
  448. template: basic_fail_1 # see https://github.com/CircleCI-Public/slack-orb/wiki#templates.
  449. recipe_accuracy_tests:
  450. docker:
  451. - image: 307629990626.dkr.ecr.us-east-1.amazonaws.com/deci/infra/circleci/runner/sg-gpu:<< pipeline.parameters.sg_docker_version >>
  452. resource_class: deci-ai/sg-gpu-on-premise
  453. parameters:
  454. sg_existing_env_path:
  455. type: string
  456. default: "/env/persistent_env"
  457. sg_new_env_name:
  458. type: string
  459. default: "${CIRCLE_BUILD_NUM}"
  460. sg_new_env_python_version:
  461. type: string
  462. default: "python3.8"
  463. steps:
  464. - checkout
  465. - run:
  466. name: install requirements and run recipe tests
  467. command: |
  468. << parameters.sg_new_env_python_version >> -m venv << parameters.sg_new_env_name >>
  469. source << parameters.sg_new_env_name >>/bin/activate
  470. python3.8 -m pip install --upgrade setuptools pip wheel
  471. python3.8 -m pip install -r requirements.txt
  472. python3.8 -m pip install .
  473. python3.8 -m pip install torch torchvision torchaudio
  474. python3.8 -m pip install pytorch-quantization==2.1.2 --extra-index-url https://pypi.ngc.nvidia.com
  475. python3.8 tests/verify_min_samples_ddp.py
  476. python3.8 src/super_gradients/train_from_recipe.py --config-name=coco2017_pose_dekr_w32_no_dc experiment_name=shortened_coco2017_pose_dekr_w32_ap_test batch_size=4 val_batch_size=8 epochs=1 training_hyperparams.lr_warmup_steps=0 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=1000 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  477. python3.8 src/super_gradients/train_from_recipe.py --config-name=cifar10_resnet experiment_name=shortened_cifar10_resnet_accuracy_test epochs=100 training_hyperparams.average_best_models=False multi_gpu=DDP num_gpus=4
  478. python3.8 src/super_gradients/examples/convert_recipe_example/convert_recipe_example.py --config-name=cifar10_conversion_params experiment_name=shortened_cifar10_resnet_accuracy_test
  479. python3.8 src/super_gradients/train_from_recipe.py --config-name=coco2017_yolox experiment_name=shortened_coco2017_yolox_n_map_test architecture=yolox_n training_hyperparams.loss=yolox_fast_loss epochs=10 training_hyperparams.average_best_models=False multi_gpu=DDP num_gpus=4
  480. python3.8 src/super_gradients/train_from_recipe.py --config-name=cityscapes_regseg48 experiment_name=shortened_cityscapes_regseg48_iou_test epochs=10 training_hyperparams.average_best_models=False multi_gpu=DDP num_gpus=4
  481. coverage run --source=super_gradients -m unittest tests/deci_core_recipe_test_suite_runner.py
  482. - run:
  483. name: Remove new environment when failed
  484. command: "rm -r << parameters.sg_new_env_name >>"
  485. when: on_fail
  486. - slack/notify:
  487. channel: "sg-integration-tests"
  488. event: fail
  489. template: basic_fail_1 # see https://github.com/CircleCI-Public/slack-orb/wiki#templates.
  490. recipe_sanity_tests_classification_pt1:
  491. docker:
  492. - image: 307629990626.dkr.ecr.us-east-1.amazonaws.com/deci/infra/circleci/runner/sg-gpu:<< pipeline.parameters.sg_docker_version >>
  493. resource_class: deci-ai/sg-gpu-on-premise
  494. parameters:
  495. sg_existing_env_path:
  496. type: string
  497. default: "/env/persistent_env"
  498. sg_new_env_name:
  499. type: string
  500. default: "${CIRCLE_BUILD_NUM}"
  501. sg_new_env_python_version:
  502. type: string
  503. default: "python3.8"
  504. steps:
  505. - checkout
  506. - run:
  507. name: install requirements and run classification sanity tests
  508. command: |
  509. << parameters.sg_new_env_python_version >> -m venv << parameters.sg_new_env_name >>
  510. source << parameters.sg_new_env_name >>/bin/activate
  511. ls /data/
  512. python3.8 -m pip install --upgrade setuptools pip wheel
  513. python3.8 -m pip install -r requirements.txt
  514. python3.8 -m pip install .
  515. python3.8 -m pip install torch torchvision torchaudio
  516. python3.8 src/super_gradients/train_from_recipe.py --config-name=imagenet_regnetY architecture=regnetY600 batch_size=8 val_batch_size=16 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4 dataset_params.train_dataset_params.root=/data/Imagenet/train dataset_params.val_dataset_params.root=/data/Imagenet/val
  517. python3.8 src/super_gradients/train_from_recipe.py --config-name=imagenet_regnetY architecture=regnetY800 batch_size=8 val_batch_size=16 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4 dataset_params.train_dataset_params.root=/data/Imagenet/train dataset_params.val_dataset_params.root=/data/Imagenet/val
  518. python3.8 src/super_gradients/train_from_recipe.py --config-name=imagenet_repvgg batch_size=8 val_batch_size=16 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4 dataset_params.train_dataset_params.root=/data/Imagenet/train dataset_params.val_dataset_params.root=/data/Imagenet/val
  519. python3.8 src/super_gradients/train_from_recipe.py --config-name=imagenet_resnet50 batch_size=8 val_batch_size=16 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4 dataset_params.train_dataset_params.root=/data/Imagenet/train dataset_params.val_dataset_params.root=/data/Imagenet/val
  520. python3.8 src/super_gradients/train_from_recipe.py --config-name=imagenet_vit_base batch_size=8 val_batch_size=16 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4 dataset_params.train_dataset_params.root=/data/Imagenet/train dataset_params.val_dataset_params.root=/data/Imagenet/val
  521. python3.8 src/super_gradients/train_from_kd_recipe.py --config-name=imagenet_resnet50_kd batch_size=8 val_batch_size=8 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4 dataset_params.train_dataset_params.root=/data/Imagenet/train dataset_params.val_dataset_params.root=/data/Imagenet/val
  522. - run:
  523. name: Remove new environment when failed
  524. command: "rm -r << parameters.sg_new_env_name >>"
  525. when: on_fail
  526. - slack/notify:
  527. channel: "sg-integration-tests"
  528. event: fail
  529. template: basic_fail_1 # see https://github.com/CircleCI-Public/slack-orb/wiki#templates.
  530. recipe_sanity_tests_classification_pt2:
  531. docker:
  532. - image: 307629990626.dkr.ecr.us-east-1.amazonaws.com/deci/infra/circleci/runner/sg-gpu:<< pipeline.parameters.sg_docker_version >>
  533. resource_class: deci-ai/sg-gpu-on-premise
  534. parameters:
  535. sg_existing_env_path:
  536. type: string
  537. default: "/env/persistent_env"
  538. sg_new_env_name:
  539. type: string
  540. default: "${CIRCLE_BUILD_NUM}"
  541. sg_new_env_python_version:
  542. type: string
  543. default: "python3.8"
  544. steps:
  545. - checkout
  546. - run:
  547. name: install requirements and run classification sanity tests
  548. command: |
  549. << parameters.sg_new_env_python_version >> -m venv << parameters.sg_new_env_name >>
  550. source << parameters.sg_new_env_name >>/bin/activate
  551. python3.8 -m pip install --upgrade setuptools pip wheel
  552. python3.8 -m pip install -r requirements.txt
  553. python3.8 -m pip install .
  554. python3.8 -m pip install torch torchvision torchaudio
  555. python3.8 src/super_gradients/train_from_recipe.py --config-name=imagenet_efficientnet batch_size=8 val_batch_size=16 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4 dataset_params.train_dataset_params.root=/data/Imagenet/train dataset_params.val_dataset_params.root=/data/Imagenet/val
  556. python3.8 src/super_gradients/train_from_recipe.py --config-name=imagenet_mobilenetv2 batch_size=8 val_batch_size=16 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4 dataset_params.train_dataset_params.root=/data/Imagenet/train dataset_params.val_dataset_params.root=/data/Imagenet/val
  557. python3.8 src/super_gradients/train_from_recipe.py --config-name=imagenet_mobilenetv3_large batch_size=8 val_batch_size=16 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4 dataset_params.train_dataset_params.root=/data/Imagenet/train dataset_params.val_dataset_params.root=/data/Imagenet/val
  558. python3.8 src/super_gradients/train_from_recipe.py --config-name=imagenet_mobilenetv3_small batch_size=8 val_batch_size=16 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4 dataset_params.train_dataset_params.root=/data/Imagenet/train dataset_params.val_dataset_params.root=/data/Imagenet/val
  559. python3.8 src/super_gradients/train_from_recipe.py --config-name=imagenet_regnetY architecture=regnetY200 batch_size=8 val_batch_size=16 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4 dataset_params.train_dataset_params.root=/data/Imagenet/train dataset_params.val_dataset_params.root=/data/Imagenet/val
  560. python3.8 src/super_gradients/train_from_recipe.py --config-name=imagenet_regnetY architecture=regnetY400 batch_size=8 val_batch_size=16 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4 dataset_params.train_dataset_params.root=/data/Imagenet/train dataset_params.val_dataset_params.root=/data/Imagenet/val
  561. - run:
  562. name: Remove new environment when failed
  563. command: "rm -r << parameters.sg_new_env_name >>"
  564. when: on_fail
  565. - slack/notify:
  566. channel: "sg-integration-tests"
  567. event: fail
  568. template: basic_fail_1 # see https://github.com/CircleCI-Public/slack-orb/wiki#templates.
  569. recipe_sanity_tests_segmentation:
  570. docker:
  571. - image: 307629990626.dkr.ecr.us-east-1.amazonaws.com/deci/infra/circleci/runner/sg-gpu:<< pipeline.parameters.sg_docker_version >>
  572. resource_class: deci-ai/sg-gpu-on-premise
  573. parameters:
  574. sg_existing_env_path:
  575. type: string
  576. default: "/env/persistent_env"
  577. sg_new_env_name:
  578. type: string
  579. default: "${CIRCLE_BUILD_NUM}"
  580. sg_new_env_python_version:
  581. type: string
  582. default: "python3.8"
  583. steps:
  584. - checkout
  585. - run:
  586. name: install requirements and run segmentation sanity tests
  587. command: |
  588. << parameters.sg_new_env_python_version >> -m venv << parameters.sg_new_env_name >>
  589. source << parameters.sg_new_env_name >>/bin/activate
  590. python3.8 -m pip install --upgrade setuptools pip wheel
  591. python3.8 -m pip install -r requirements.txt
  592. python3.8 -m pip install .
  593. python3.8 -m pip install torch torchvision torchaudio
  594. wget -O $(pwd)/checkpoints/ddrnet23_slim_bb_imagenet.pth https://deci-pretrained-models.s3.amazonaws.com/ddrnet/imagenet_pt_backbones/ddrnet23_slim_bb_imagenet.pth
  595. wget -O $(pwd)/checkpoints/ddrnet23_bb_imagenet.pth https://deci-pretrained-models.s3.amazonaws.com/ddrnet/imagenet_pt_backbones/ddrnet23_bb_imagenet.pth
  596. wget -O $(pwd)/checkpoints/ddrnet39_imagenet_pretrained.pth https://deci-pretrained-models.s3.amazonaws.com/ddrnet/imagenet_pt_backbones/ddrnet39_bb_imagenet.pth
  597. python3.8 src/super_gradients/train_from_recipe.py --config-name=cityscapes_ddrnet checkpoint_params.checkpoint_path=$(pwd)/checkpoints/ddrnet23_bb_imagenet.pth batch_size=3 val_batch_size=3 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  598. python3.8 src/super_gradients/train_from_recipe.py --config-name=cityscapes_ddrnet architecture=ddrnet_23_slim checkpoint_params.checkpoint_path=$(pwd)/checkpoints/ddrnet23_slim_bb_imagenet.pth batch_size=3 val_batch_size=3 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  599. python3.8 src/super_gradients/train_from_recipe.py --config-name=cityscapes_ddrnet checkpoint_params.checkpoint_path=$(pwd)/checkpoints/ddrnet39_imagenet_pretrained.pth architecture=ddrnet_39 batch_size=3 val_batch_size=3 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  600. wget -O $(pwd)/checkpoints/stdc1_imagenet_pretrained.pth https://deci-pretrained-models.s3.amazonaws.com/stdc_backbones/stdc1_imagenet_pretrained.pth
  601. wget -O $(pwd)/checkpoints/stdc2_imagenet_pretrained.pth https://deci-pretrained-models.s3.amazonaws.com/stdc_backbones/stdc2_imagenet_pretrained.pth
  602. python3.8 src/super_gradients/train_from_recipe.py --config-name=cityscapes_pplite_seg50 checkpoint_params.checkpoint_path=$(pwd)/checkpoints/stdc1_imagenet_pretrained.pth architecture=pp_lite_t_seg batch_size=3 val_batch_size=3 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  603. python3.8 src/super_gradients/train_from_recipe.py --config-name=cityscapes_pplite_seg50 checkpoint_params.checkpoint_path=$(pwd)/checkpoints/stdc2_imagenet_pretrained.pth architecture=pp_lite_b_seg batch_size=3 val_batch_size=3 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  604. python3.8 src/super_gradients/train_from_recipe.py --config-name=cityscapes_pplite_seg75 checkpoint_params.checkpoint_path=$(pwd)/checkpoints/stdc1_imagenet_pretrained.pth architecture=pp_lite_t_seg batch_size=3 val_batch_size=3 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  605. python3.8 src/super_gradients/train_from_recipe.py --config-name=cityscapes_pplite_seg75 checkpoint_params.checkpoint_path=$(pwd)/checkpoints/stdc2_imagenet_pretrained.pth architecture=pp_lite_b_seg batch_size=3 val_batch_size=3 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  606. python3.8 src/super_gradients/train_from_recipe.py --config-name=cityscapes_stdc_seg50 checkpoint_params.checkpoint_path=$(pwd)/checkpoints/stdc1_imagenet_pretrained.pth batch_size=3 val_batch_size=3 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  607. python3.8 src/super_gradients/train_from_recipe.py --config-name=cityscapes_stdc_seg50 checkpoint_params.checkpoint_path=$(pwd)/checkpoints/stdc2_imagenet_pretrained.pth architecture=stdc2_seg batch_size=3 val_batch_size=3 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  608. python3.8 src/super_gradients/train_from_recipe.py --config-name=cityscapes_stdc_seg75 checkpoint_params.checkpoint_path=$(pwd)/checkpoints/stdc1_imagenet_pretrained.pth batch_size=3 val_batch_size=3 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  609. python3.8 src/super_gradients/train_from_recipe.py --config-name=cityscapes_stdc_seg75 checkpoint_params.checkpoint_path=$(pwd)/checkpoints/stdc2_imagenet_pretrained.pth architecture=stdc2_seg batch_size=3 val_batch_size=3 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  610. - run:
  611. name: Remove new environment when failed
  612. command: "rm -r << parameters.sg_new_env_name >>"
  613. when: on_fail
  614. - slack/notify:
  615. channel: "sg-integration-tests"
  616. event: fail
  617. template: basic_fail_1 # see https://github.com/CircleCI-Public/slack-orb/wiki#templates.
  618. recipe_sanity_tests_detection:
  619. docker:
  620. - image: 307629990626.dkr.ecr.us-east-1.amazonaws.com/deci/infra/circleci/runner/sg-gpu:<< pipeline.parameters.sg_docker_version >>
  621. resource_class: deci-ai/sg-gpu-on-premise
  622. parameters:
  623. sg_existing_env_path:
  624. type: string
  625. default: "/env/persistent_env"
  626. sg_new_env_name:
  627. type: string
  628. default: "${CIRCLE_BUILD_NUM}"
  629. sg_new_env_python_version:
  630. type: string
  631. default: "python3.8"
  632. steps:
  633. - checkout
  634. - run:
  635. name: install requirements and run detection sanity tests
  636. command: |
  637. << parameters.sg_new_env_python_version >> -m venv << parameters.sg_new_env_name >>
  638. source << parameters.sg_new_env_name >>/bin/activate
  639. python3.8 -m pip install --upgrade setuptools pip wheel
  640. python3.8 -m pip install -r requirements.txt
  641. python3.8 -m pip install .
  642. python3.8 -m pip install torch torchvision torchaudio
  643. python3.8 src/super_gradients/train_from_recipe.py --config-name=coco2017_ssd_lite_mobilenet_v2 batch_size=8 val_batch_size=16 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  644. python3.8 src/super_gradients/train_from_recipe.py --config-name=coco2017_yolox architecture=yolox_n batch_size=8 val_batch_size=16 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  645. python3.8 src/super_gradients/train_from_recipe.py --config-name=coco2017_yolox architecture=yolox_t batch_size=8 val_batch_size=16 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  646. python3.8 src/super_gradients/train_from_recipe.py --config-name=coco2017_yolox architecture=yolox_s batch_size=8 val_batch_size=16 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  647. python3.8 src/super_gradients/train_from_recipe.py --config-name=coco2017_yolox architecture=yolox_m batch_size=8 val_batch_size=8 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  648. python3.8 src/super_gradients/train_from_recipe.py --config-name=coco2017_yolox architecture=yolox_l batch_size=4 val_batch_size=8 epochs=1 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=100 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  649. - run:
  650. name: Remove new environment when failed
  651. command: "rm -r << parameters.sg_new_env_name >>"
  652. when: on_fail
  653. - slack/notify:
  654. channel: "sg-integration-tests"
  655. event: fail
  656. template: basic_fail_1 # see https://github.com/CircleCI-Public/slack-orb/wiki#templates.
  657. recipe_sanity_tests_pose_estimation:
  658. docker:
  659. - image: 307629990626.dkr.ecr.us-east-1.amazonaws.com/deci/infra/circleci/runner/sg-gpu:<< pipeline.parameters.sg_docker_version >>
  660. resource_class: deci-ai/sg-gpu-on-premise
  661. parameters:
  662. sg_existing_env_path:
  663. type: string
  664. default: "/env/persistent_env"
  665. sg_new_env_name:
  666. type: string
  667. default: "${CIRCLE_BUILD_NUM}"
  668. sg_new_env_python_version:
  669. type: string
  670. default: "python3.8"
  671. steps:
  672. - checkout
  673. - run:
  674. name: install requirements and run pose estimation sanity tests
  675. command: |
  676. << parameters.sg_new_env_python_version >> -m venv << parameters.sg_new_env_name >>
  677. source << parameters.sg_new_env_name >>/bin/activate
  678. python3.8 -m pip install --upgrade setuptools pip wheel
  679. python3.8 -m pip install -r requirements.txt
  680. python3.8 -m pip install .
  681. python3.8 -m pip install torch torchvision torchaudio
  682. python3.8 src/super_gradients/train_from_recipe.py --config-name=coco2017_pose_dekr_w32_no_dc experiment_name=shortened_coco2017_pose_dekr_w32_ap_test batch_size=4 val_batch_size=8 epochs=1 training_hyperparams.lr_warmup_steps=0 training_hyperparams.average_best_models=False training_hyperparams.max_train_batches=1000 training_hyperparams.max_valid_batches=100 multi_gpu=DDP num_gpus=4
  683. - run:
  684. name: Remove new environment when failed
  685. command: "rm -r << parameters.sg_new_env_name >>"
  686. when: on_fail
  687. - slack/notify:
  688. channel: "sg-integration-tests"
  689. event: fail
  690. template: basic_fail_1 # see https://github.com/CircleCI-Public/slack-orb/wiki#templates.
  691. docker-build-and-publish-branch:
  692. docker:
  693. - image: cimg/base:stable-20.04
  694. parameters:
  695. repo_name:
  696. type: string
  697. default: "deci/super-gradients"
  698. docker_context:
  699. type: string
  700. default: "."
  701. additional_tags:
  702. type: string
  703. default: ''
  704. steps:
  705. - setup_remote_docker:
  706. version: 20.10.7
  707. docker_layer_caching: true
  708. - deci-common/container_image_lint_tag:
  709. image_tag: "${CIRCLE_BRANCH}"
  710. - run:
  711. command: |
  712. ADDITIONAL_TAGS="<< parameters.additional_tags >>"
  713. echo "export ADDITIONAL_TAGS=${ADDITIONAL_TAGS}" >> $BASH_ENV
  714. - run:
  715. command: |
  716. source $BASH_ENV
  717. echo "$CONTAINER_LINT_TAG"
  718. echo "$ADDITIONAL_TAGS"
  719. - when:
  720. condition: << pipeline.parameters.ad_hoc_container_build_code_only >>
  721. steps:
  722. - build_and_publish_command:
  723. repo_name: << parameters.repo_name >>
  724. docker_context: << parameters.docker_context >>
  725. image_tag: $CONTAINER_LINT_TAG
  726. additional_tags: $ADDITIONAL_TAGS
  727. dockerfile: 'scripts/Dockerfile.branch.code'
  728. build_args: "BASE_TAG=$CONTAINER_LINT_TAG"
  729. - unless:
  730. condition: << pipeline.parameters.ad_hoc_container_build_code_only >>
  731. steps:
  732. - build_and_publish_command:
  733. repo_name: << parameters.repo_name >>
  734. docker_context: << parameters.docker_context >>
  735. image_tag: $CONTAINER_LINT_TAG
  736. additional_tags: $ADDITIONAL_TAGS
  737. dockerfile: 'scripts/Dockerfile.branch'
  738. workflows:
  739. sanity_tests:
  740. when: << pipeline.parameters.run_sanity_tests_flow >>
  741. jobs:
  742. - hydra_sweeper_test:
  743. context:
  744. - slack
  745. - recipe_sanity_tests_classification_pt1:
  746. context:
  747. - slack
  748. - recipe_sanity_tests_classification_pt2:
  749. context:
  750. - slack
  751. - recipe_sanity_tests_segmentation:
  752. context:
  753. - slack
  754. - recipe_sanity_tests_detection:
  755. context:
  756. - slack
  757. - recipe_sanity_tests_pose_estimation:
  758. context:
  759. - slack
  760. - recipe_accuracy_tests:
  761. context:
  762. - slack
  763. release:
  764. unless:
  765. or:
  766. - << pipeline.parameters.ad_hoc_container_build >>
  767. - << pipeline.parameters.ad_hoc_container_build_code_only >>
  768. jobs:
  769. - deci-common/persist_version_info:
  770. version_override: $CIRCLE_TAG
  771. <<: *release_tag_filter
  772. - deci-common/codeartifact_login:
  773. name: "login_to_codeartifact_release"
  774. repo_name: "deci-packages"
  775. <<: *release_tag_filter
  776. - build:
  777. name: "build3.8"
  778. py_version: "3.8"
  779. package_name: "super-gradients"
  780. requires:
  781. - deci-common/persist_version_info
  782. - login_to_codeartifact_release
  783. <<: *release_tag_filter
  784. - hydra_sweeper_test:
  785. context:
  786. - slack
  787. <<: *release_tag_filter
  788. - recipe_sanity_tests_classification_pt1:
  789. context:
  790. - slack
  791. <<: *release_tag_filter
  792. - recipe_sanity_tests_classification_pt2:
  793. context:
  794. - slack
  795. <<: *release_tag_filter
  796. - recipe_sanity_tests_segmentation:
  797. context:
  798. - slack
  799. <<: *release_tag_filter
  800. - recipe_sanity_tests_detection:
  801. context:
  802. - slack
  803. <<: *release_tag_filter
  804. - recipe_sanity_tests_pose_estimation:
  805. context:
  806. - slack
  807. <<: *release_tag_filter
  808. - recipe_accuracy_tests:
  809. context:
  810. - slack
  811. <<: *release_tag_filter
  812. - release_version:
  813. py_version: "3.8"
  814. requires:
  815. - "build3.8"
  816. - hydra_sweeper_test
  817. - recipe_accuracy_tests
  818. - recipe_sanity_tests_classification_pt1
  819. - recipe_sanity_tests_classification_pt2
  820. - recipe_sanity_tests_segmentation
  821. - recipe_sanity_tests_detection
  822. - recipe_sanity_tests_pose_estimation
  823. <<: *release_tag_filter
  824. - deci-common/pip_upload_package_from_codeartifact_to_global_pypi:
  825. package_name: "super-gradients"
  826. name: "upload_super_gradients_to_pypi"
  827. version: $CIRCLE_TAG
  828. requires:
  829. - "release_version"
  830. context:
  831. - pypi-supergradients
  832. <<: *release_tag_filter
  833. build_and_deploy:
  834. unless:
  835. or:
  836. - << pipeline.parameters.ad_hoc_container_build >>
  837. - << pipeline.parameters.ad_hoc_container_build_code_only >>
  838. jobs:
  839. - deci-common/persist_version_info:
  840. use_rc: true
  841. use_beta: false
  842. version_override: ""
  843. - build:
  844. name: "build<< pipeline.parameters.build_py_version >>"
  845. py_version: << pipeline.parameters.build_py_version >>
  846. package_name: "super-gradients"
  847. requires:
  848. - deci-common/persist_version_info
  849. - deci-common/codeartifact_login:
  850. repo_name: "deci-packages"
  851. <<: *release_candidate_filter
  852. - release_candidate: # happens on merge
  853. py_version: "<< pipeline.parameters.build_py_version >>"
  854. requires:
  855. - "build<< pipeline.parameters.build_py_version >>"
  856. - deci-common/codeartifact_login
  857. <<: *release_candidate_filter
  858. SG_docker:
  859. unless:
  860. or:
  861. - << pipeline.parameters.ad_hoc_container_build >>
  862. - << pipeline.parameters.ad_hoc_container_build_code_only >>
  863. jobs:
  864. - change_rc_to_b: # works on release candidate creation
  865. <<: *release_candidate_tag_filter
  866. - build_and_publish_sg_container: # works on release candidate creation
  867. requires:
  868. - "change_rc_to_b"
  869. <<: *release_candidate_tag_filter
  870. - testing_supergradients_docker_image: # works on release candidate creation
  871. image_repo: '307629990626.dkr.ecr.us-east-1.amazonaws.com/deci/super-gradients'
  872. requires:
  873. - "build_and_publish_sg_container"
  874. - "change_rc_to_b"
  875. <<: *release_candidate_tag_filter
  876. - add_rc_tag_to_beta: # works on release candidate creation for ECR Repo
  877. requires:
  878. - "testing_supergradients_docker_image"
  879. - "change_rc_to_b"
  880. <<: *release_candidate_tag_filter
  881. - find_rc_tag_per_sha: # works on release
  882. <<: *release_tag_filter
  883. - add_release_tag_to_rc: # works on release
  884. requires:
  885. - "find_rc_tag_per_sha"
  886. <<: *release_tag_filter
  887. - slack/on-hold:
  888. context: slack
  889. channel: "sg-integration-tests"
  890. requires:
  891. - "add_release_tag_to_rc"
  892. <<: *release_tag_filter
  893. - hold-sg-public-release: # works on release
  894. type: approval
  895. requires:
  896. - "slack/on-hold"
  897. <<: *release_tag_filter
  898. - docker/publish: # works on release
  899. executor:
  900. image: cimg/base
  901. tag: stable-20.04
  902. name: docker/docker
  903. image: deciai/super-gradients
  904. remote-docker-version: << pipeline.parameters.remote_docker_version >>
  905. update-description: true
  906. use-buildkit: true
  907. use-remote-docker: true
  908. use-docker-credentials-store: true
  909. path: ./scripts
  910. readme: ../README.md
  911. tag: latest,${CIRCLE_TAG}
  912. extra_build_args: '--build-arg VERSION=${CIRCLE_TAG}' #building from scratch as it faster and cheaper than download and retag
  913. requires:
  914. - "hold-sg-public-release"
  915. <<: *release_tag_filter
  916. - docker/publish: # works on release
  917. executor:
  918. image: cimg/base
  919. tag: stable-20.04
  920. name: docker/docker
  921. image: deciai/super-gradients
  922. remote-docker-version: << pipeline.parameters.remote_docker_version >>
  923. update-description: false
  924. use-buildkit: true
  925. use-remote-docker: true
  926. use-docker-credentials-store: true
  927. path: ./scripts
  928. tag: ${CIRCLE_TAG}-runtime
  929. extra_build_args: '--build-arg VERSION=${CIRCLE_TAG} --build-arg DOCKER_IMAGE_TAG=11.3.1-runtime-ubuntu20.04'
  930. requires:
  931. - "hold-sg-public-release"
  932. <<: *release_tag_filter
  933. build-and-push-container-flow:
  934. when: << pipeline.parameters.ad_hoc_container_build >>
  935. jobs:
  936. - docker-build-and-publish-branch
  937. build-and-push-container-code-only-flow:
  938. when: << pipeline.parameters.ad_hoc_container_build_code_only >>
  939. jobs:
  940. - docker-build-and-publish-branch
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...