@grnsft/if 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (285) hide show
  1. package/.devcontainer/devcontainer.json +38 -0
  2. package/.editorconfig +8 -0
  3. package/.env.example +9 -0
  4. package/.eslintignore +4 -0
  5. package/.eslintrc.json +8 -0
  6. package/.github/ISSUE_TEMPLATE/agenda.md +36 -0
  7. package/.github/ISSUE_TEMPLATE/blank-issue.md +10 -0
  8. package/.github/ISSUE_TEMPLATE/feedback.md +42 -0
  9. package/.github/ISSUE_TEMPLATE/model-plugin.md +63 -0
  10. package/.github/ISSUE_TEMPLATE/user-story.md +10 -0
  11. package/.github/PULL_REQUEST_TEMPLATE.md +21 -0
  12. package/.github/workflows/nodejs-ci.yml +34 -0
  13. package/.gitmodules +3 -0
  14. package/.prettierrc.js +3 -0
  15. package/CONTRIBUTING.md +194 -0
  16. package/LICENSE +21 -0
  17. package/Makefile +16 -0
  18. package/README.md +67 -0
  19. package/build/__mocks__/azure/index.d.ts +11 -0
  20. package/build/__mocks__/azure/index.js +132 -0
  21. package/build/__mocks__/boavizta/countries.json +138 -0
  22. package/build/__mocks__/boavizta/instance_types.json +625 -0
  23. package/build/__mocks__/boavizta/providers.json +1 -0
  24. package/build/__mocks__/fs/index.d.ts +3 -0
  25. package/build/__mocks__/fs/index.js +56 -0
  26. package/build/__mocks__/model-universe/index.d.ts +33 -0
  27. package/build/__mocks__/model-universe/index.js +68 -0
  28. package/build/__mocks__/watt-time/data.json +119 -0
  29. package/build/__tests__/integration/ompl/index.test.d.ts +1 -0
  30. package/build/__tests__/integration/ompl/index.test.js +61 -0
  31. package/build/__tests__/unit/lib/azure-importer/index.test.d.ts +1 -0
  32. package/build/__tests__/unit/lib/azure-importer/index.test.js +152 -0
  33. package/build/__tests__/unit/lib/boavizta/index.test.d.ts +1 -0
  34. package/build/__tests__/unit/lib/boavizta/index.test.js +579 -0
  35. package/build/__tests__/unit/lib/case-studies/aveva.test.d.ts +1 -0
  36. package/build/__tests__/unit/lib/case-studies/aveva.test.js +36 -0
  37. package/build/__tests__/unit/lib/case-studies/emem.test.d.ts +1 -0
  38. package/build/__tests__/unit/lib/case-studies/emem.test.js +108 -0
  39. package/build/__tests__/unit/lib/case-studies/eshoppen.test.d.ts +1 -0
  40. package/build/__tests__/unit/lib/case-studies/eshoppen.test.js +53 -0
  41. package/build/__tests__/unit/lib/case-studies/sci-accenture.test.d.ts +1 -0
  42. package/build/__tests__/unit/lib/case-studies/sci-accenture.test.js +23 -0
  43. package/build/__tests__/unit/lib/ccf/index.test.d.ts +1 -0
  44. package/build/__tests__/unit/lib/ccf/index.test.js +223 -0
  45. package/build/__tests__/unit/lib/cloud-instance-metadata/index.test.d.ts +1 -0
  46. package/build/__tests__/unit/lib/cloud-instance-metadata/index.test.js +73 -0
  47. package/build/__tests__/unit/lib/sci/index.test.d.ts +1 -0
  48. package/build/__tests__/unit/lib/sci/index.test.js +106 -0
  49. package/build/__tests__/unit/lib/sci-e/index.test.d.ts +1 -0
  50. package/build/__tests__/unit/lib/sci-e/index.test.js +30 -0
  51. package/build/__tests__/unit/lib/sci-m/index.test.d.ts +1 -0
  52. package/build/__tests__/unit/lib/sci-m/index.test.js +58 -0
  53. package/build/__tests__/unit/lib/sci-o/index.test.d.ts +1 -0
  54. package/build/__tests__/unit/lib/sci-o/index.test.js +42 -0
  55. package/build/__tests__/unit/lib/shell-imp/index.test.d.ts +1 -0
  56. package/build/__tests__/unit/lib/shell-imp/index.test.js +21 -0
  57. package/build/__tests__/unit/lib/tdp-finder/index.test.d.ts +1 -0
  58. package/build/__tests__/unit/lib/tdp-finder/index.test.js +62 -0
  59. package/build/__tests__/unit/lib/teads-aws/index.test.d.ts +1 -0
  60. package/build/__tests__/unit/lib/teads-aws/index.test.js +170 -0
  61. package/build/__tests__/unit/lib/teads-curve/index.test.d.ts +1 -0
  62. package/build/__tests__/unit/lib/teads-curve/index.test.js +146 -0
  63. package/build/__tests__/unit/lib/watt-time/index.test.d.ts +1 -0
  64. package/build/__tests__/unit/lib/watt-time/index.test.js +106 -0
  65. package/build/__tests__/unit/util/args.test.d.ts +1 -0
  66. package/build/__tests__/unit/util/args.test.js +92 -0
  67. package/build/__tests__/unit/util/models-universe.test.d.ts +1 -0
  68. package/build/__tests__/unit/util/models-universe.test.js +211 -0
  69. package/build/__tests__/unit/util/observatory.test.d.ts +1 -0
  70. package/build/__tests__/unit/util/observatory.test.js +91 -0
  71. package/build/__tests__/unit/util/supercomputer.test.d.ts +1 -0
  72. package/build/__tests__/unit/util/supercomputer.test.js +231 -0
  73. package/build/__tests__/unit/util/yaml.test.d.ts +1 -0
  74. package/build/__tests__/unit/util/yaml.test.js +59 -0
  75. package/build/config/config.d.ts +32 -0
  76. package/build/config/config.js +74 -0
  77. package/build/config/index.d.ts +2 -0
  78. package/build/config/index.js +8 -0
  79. package/build/config/strings.d.ts +14 -0
  80. package/build/config/strings.js +30 -0
  81. package/build/index.d.ts +1 -0
  82. package/build/index.js +46 -0
  83. package/build/lib/azure-importer/index.d.ts +55 -0
  84. package/build/lib/azure-importer/index.js +314 -0
  85. package/build/lib/boavizta/index.d.ts +53 -0
  86. package/build/lib/boavizta/index.js +254 -0
  87. package/build/lib/case-studies/aveva-model.d.ts +29 -0
  88. package/build/lib/case-studies/aveva-model.js +53 -0
  89. package/build/lib/case-studies/emem-model.d.ts +42 -0
  90. package/build/lib/case-studies/emem-model.js +93 -0
  91. package/build/lib/case-studies/eshoppen-model.d.ts +24 -0
  92. package/build/lib/case-studies/eshoppen-model.js +123 -0
  93. package/build/lib/case-studies/index.d.ts +4 -0
  94. package/build/lib/case-studies/index.js +21 -0
  95. package/build/lib/case-studies/sci-accenture-model.d.ts +10 -0
  96. package/build/lib/case-studies/sci-accenture-model.js +37 -0
  97. package/build/lib/ccf/aws-embodied.json +5591 -0
  98. package/build/lib/ccf/aws-instances.json +21116 -0
  99. package/build/lib/ccf/aws-use.json +79 -0
  100. package/build/lib/ccf/azure-embodied.json +6547 -0
  101. package/build/lib/ccf/azure-instances.json +8332 -0
  102. package/build/lib/ccf/azure-use.json +58 -0
  103. package/build/lib/ccf/gcp-embodied.json +3049 -0
  104. package/build/lib/ccf/gcp-instances.json +3880 -0
  105. package/build/lib/ccf/gcp-use.json +58 -0
  106. package/build/lib/ccf/index.d.ts +63 -0
  107. package/build/lib/ccf/index.js +338 -0
  108. package/build/lib/cloud-instance-metadata/aws-instances.json +1 -0
  109. package/build/lib/cloud-instance-metadata/azure-instances.json +1 -0
  110. package/build/lib/cloud-instance-metadata/index.d.ts +15 -0
  111. package/build/lib/cloud-instance-metadata/index.js +104 -0
  112. package/build/lib/index.d.ts +15 -0
  113. package/build/lib/index.js +32 -0
  114. package/build/lib/interfaces/ccf.d.ts +19 -0
  115. package/build/lib/interfaces/ccf.js +3 -0
  116. package/build/lib/interfaces/index.d.ts +7 -0
  117. package/build/lib/interfaces/index.js +18 -0
  118. package/build/lib/sci/index.d.ts +13 -0
  119. package/build/lib/sci/index.js +131 -0
  120. package/build/lib/sci-e/index.d.ts +38 -0
  121. package/build/lib/sci-e/index.js +85 -0
  122. package/build/lib/sci-m/index.d.ts +10 -0
  123. package/build/lib/sci-m/index.js +124 -0
  124. package/build/lib/sci-o/index.d.ts +17 -0
  125. package/build/lib/sci-o/index.js +52 -0
  126. package/build/lib/shell-imp/index.d.ts +32 -0
  127. package/build/lib/shell-imp/index.js +82 -0
  128. package/build/lib/tdp-finder/index.d.ts +19 -0
  129. package/build/lib/tdp-finder/index.js +98 -0
  130. package/build/lib/teads-aws/aws-embodied.json +1 -0
  131. package/build/lib/teads-aws/aws-instances.json +1 -0
  132. package/build/lib/teads-aws/index.d.ts +58 -0
  133. package/build/lib/teads-aws/index.js +208 -0
  134. package/build/lib/teads-curve/index.d.ts +52 -0
  135. package/build/lib/teads-curve/index.js +158 -0
  136. package/build/lib/watt-time/index.d.ts +18 -0
  137. package/build/lib/watt-time/index.js +204 -0
  138. package/build/types/azure-importer.d.ts +29 -0
  139. package/build/types/azure-importer.js +3 -0
  140. package/build/types/boavizta.d.ts +7 -0
  141. package/build/types/boavizta.js +3 -0
  142. package/build/types/common.d.ts +7 -0
  143. package/build/types/common.js +9 -0
  144. package/build/types/impl.d.ts +40 -0
  145. package/build/types/impl.js +3 -0
  146. package/build/types/models-universe.d.ts +24 -0
  147. package/build/types/models-universe.js +3 -0
  148. package/build/types/process-args.d.ts +7 -0
  149. package/build/types/process-args.js +3 -0
  150. package/build/types/supercomputer.d.ts +4 -0
  151. package/build/types/supercomputer.js +3 -0
  152. package/build/util/args.d.ts +8 -0
  153. package/build/util/args.js +48 -0
  154. package/build/util/errors.d.ts +6 -0
  155. package/build/util/errors.js +22 -0
  156. package/build/util/helpers.d.ts +4 -0
  157. package/build/util/helpers.js +18 -0
  158. package/build/util/models-universe.d.ts +28 -0
  159. package/build/util/models-universe.js +95 -0
  160. package/build/util/observatory.d.ts +20 -0
  161. package/build/util/observatory.js +31 -0
  162. package/build/util/supercomputer.d.ts +30 -0
  163. package/build/util/supercomputer.js +109 -0
  164. package/build/util/validations.d.ts +25 -0
  165. package/build/util/validations.js +52 -0
  166. package/build/util/yaml.d.ts +13 -0
  167. package/build/util/yaml.js +36 -0
  168. package/coverage/clover.xml +1172 -0
  169. package/coverage/coverage-final.json +27 -0
  170. package/coverage/lcov-report/base.css +224 -0
  171. package/coverage/lcov-report/block-navigation.js +87 -0
  172. package/coverage/lcov-report/config/config.ts.html +310 -0
  173. package/coverage/lcov-report/config/index.html +146 -0
  174. package/coverage/lcov-report/config/index.ts.html +91 -0
  175. package/coverage/lcov-report/config/strings.ts.html +118 -0
  176. package/coverage/lcov-report/favicon.png +0 -0
  177. package/coverage/lcov-report/index.html +341 -0
  178. package/coverage/lcov-report/lib/boavizta/index.html +116 -0
  179. package/coverage/lcov-report/lib/boavizta/index.ts.html +1171 -0
  180. package/coverage/lcov-report/lib/case-studies/aveva-model.ts.html +277 -0
  181. package/coverage/lcov-report/lib/case-studies/emem-model.ts.html +439 -0
  182. package/coverage/lcov-report/lib/case-studies/eshoppen-model.ts.html +550 -0
  183. package/coverage/lcov-report/lib/case-studies/index.html +176 -0
  184. package/coverage/lcov-report/lib/case-studies/index.ts.html +97 -0
  185. package/coverage/lcov-report/lib/case-studies/sci-accenture-model.ts.html +232 -0
  186. package/coverage/lcov-report/lib/ccf/index.html +116 -0
  187. package/coverage/lcov-report/lib/ccf/index.ts.html +1339 -0
  188. package/coverage/lcov-report/lib/cloud-instance-metadata/index.html +116 -0
  189. package/coverage/lcov-report/lib/cloud-instance-metadata/index.ts.html +370 -0
  190. package/coverage/lcov-report/lib/index.html +116 -0
  191. package/coverage/lcov-report/lib/index.ts.html +121 -0
  192. package/coverage/lcov-report/lib/sci/index.html +116 -0
  193. package/coverage/lcov-report/lib/sci/index.ts.html +571 -0
  194. package/coverage/lcov-report/lib/sci-e/index.html +116 -0
  195. package/coverage/lcov-report/lib/sci-e/index.ts.html +403 -0
  196. package/coverage/lcov-report/lib/sci-m/index.html +116 -0
  197. package/coverage/lcov-report/lib/sci-m/index.ts.html +487 -0
  198. package/coverage/lcov-report/lib/sci-o/index.html +116 -0
  199. package/coverage/lcov-report/lib/sci-o/index.ts.html +265 -0
  200. package/coverage/lcov-report/lib/shell-imp/index.html +116 -0
  201. package/coverage/lcov-report/lib/shell-imp/index.ts.html +376 -0
  202. package/coverage/lcov-report/lib/teads-aws/index.html +116 -0
  203. package/coverage/lcov-report/lib/teads-aws/index.ts.html +823 -0
  204. package/coverage/lcov-report/lib/teads-curve/index.html +116 -0
  205. package/coverage/lcov-report/lib/teads-curve/index.ts.html +625 -0
  206. package/coverage/lcov-report/lib/watt-time/index.html +116 -0
  207. package/coverage/lcov-report/lib/watt-time/index.ts.html +829 -0
  208. package/coverage/lcov-report/prettify.css +1 -0
  209. package/coverage/lcov-report/prettify.js +2 -0
  210. package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
  211. package/coverage/lcov-report/sorter.js +196 -0
  212. package/coverage/lcov-report/types/common.ts.html +109 -0
  213. package/coverage/lcov-report/types/index.html +116 -0
  214. package/coverage/lcov-report/util/args.ts.html +244 -0
  215. package/coverage/lcov-report/util/index.html +176 -0
  216. package/coverage/lcov-report/util/models-universe.ts.html +679 -0
  217. package/coverage/lcov-report/util/observatory.ts.html +229 -0
  218. package/coverage/lcov-report/util/supercomputer.ts.html +466 -0
  219. package/coverage/lcov-report/util/yaml.ts.html +193 -0
  220. package/coverage/lcov.info +2094 -0
  221. package/docs/implementations/tdp-finder.md +36 -0
  222. package/examples/impls/case-studies/accenture.yml +155 -0
  223. package/examples/impls/case-studies/aveva.yaml +48 -0
  224. package/examples/impls/case-studies/azure-yassine.yaml +67 -0
  225. package/examples/impls/case-studies/boavizta.yml +26 -0
  226. package/examples/impls/case-studies/dow_msft.yml +173 -0
  227. package/examples/impls/case-studies/farm-insights.yaml +35 -0
  228. package/examples/impls/case-studies/gsf-website.yaml +93 -0
  229. package/examples/impls/case-studies/msft-eshoppen.yaml +162 -0
  230. package/examples/impls/case-studies/msft-green-ai.yaml +58 -0
  231. package/examples/impls/case-studies/ntt-data-on-premise.yaml +201 -0
  232. package/examples/impls/tdp-finder-test.yml +19 -0
  233. package/examples/impls/test/azure.yml +26 -0
  234. package/examples/impls/test/ccf.yml +19 -0
  235. package/examples/impls/test/complex-pipeline.yml +67 -0
  236. package/examples/impls/test/if-demo.yml +51 -0
  237. package/examples/impls/test/metadata.yml +20 -0
  238. package/examples/impls/test/nesting.yml +65 -0
  239. package/examples/impls/test/sci-e.yml +21 -0
  240. package/examples/impls/test/sci-m.yml +24 -0
  241. package/examples/impls/test/sci-o.yml +28 -0
  242. package/examples/impls/test/sci.yml +27 -0
  243. package/examples/impls/test/shell.yml +18 -0
  244. package/examples/impls/test/toto.yaml +22 -0
  245. package/examples/ompls/azure.yml +145 -0
  246. package/examples/ompls/ccf.yml +27 -0
  247. package/examples/ompls/complex-pipeline.yml +105 -0
  248. package/examples/ompls/full-sci.yml +64 -0
  249. package/examples/ompls/if-demo.yml +493 -0
  250. package/examples/ompls/metadata.yml +29 -0
  251. package/examples/ompls/nesting.yml +107 -0
  252. package/examples/ompls/sci-e.yml +23 -0
  253. package/examples/ompls/sci-m.yml +33 -0
  254. package/examples/ompls/sci-o.yml +29 -0
  255. package/examples/ompls/sci.yml +36 -0
  256. package/examples/ompls/shell.yml +23 -0
  257. package/jest.config.js +14 -0
  258. package/package.json +71 -0
  259. package/scripts/impact-test.sh +12 -0
  260. package/src/__mocks__/boavizta/countries.json +138 -0
  261. package/src/__mocks__/boavizta/instance_types.json +625 -0
  262. package/src/__mocks__/boavizta/providers.json +1 -0
  263. package/src/__mocks__/watt-time/data.json +119 -0
  264. package/src/config/units.yaml +125 -0
  265. package/src/lib/ccf/aws-embodied.json +5591 -0
  266. package/src/lib/ccf/aws-instances.json +21116 -0
  267. package/src/lib/ccf/aws-use.json +79 -0
  268. package/src/lib/ccf/azure-embodied.json +6547 -0
  269. package/src/lib/ccf/azure-instances.json +8332 -0
  270. package/src/lib/ccf/azure-use.json +58 -0
  271. package/src/lib/ccf/gcp-embodied.json +3049 -0
  272. package/src/lib/ccf/gcp-instances.json +3880 -0
  273. package/src/lib/ccf/gcp-use.json +58 -0
  274. package/src/lib/cloud-instance-metadata/aws-instances.json +1 -0
  275. package/src/lib/cloud-instance-metadata/azure-instances.json +1 -0
  276. package/src/lib/shell-imp/sampler +30 -0
  277. package/src/lib/tdp-finder/README.md +7 -0
  278. package/src/lib/tdp-finder/boavizta_data.csv +1768 -0
  279. package/src/lib/tdp-finder/data.csv +4460 -0
  280. package/src/lib/tdp-finder/data2.csv +2162 -0
  281. package/src/lib/teads-aws/aws-embodied.json +1 -0
  282. package/src/lib/teads-aws/aws-instances.json +1 -0
  283. package/tsconfig.test.json +39 -0
  284. package/tsconfig.tsbuildinfo +1 -0
  285. package/yarn-error.log +5854 -0
@@ -0,0 +1,162 @@
1
+ name: msft-eshoppen
2
+ description: https://github.com/Green-Software-Foundation/sci-guide/blob/dev/use-case-submissions/msft-eShoppen.md
3
+ tags:
4
+ kind: web
5
+ complexity: moderate
6
+ category: cloud
7
+ initialize:
8
+ models:
9
+ - name: eshoppen-cpu # calculates e due to memory util ((mem-util * mem-allocated * mem-energy)/1000 = energy-memory)
10
+ kind: energy-cpu
11
+ path: false
12
+ verbose: false
13
+ - name: eshoppen-mem # calculates e due to memory util ((mem-util * mem-allocated * mem-energy)/1000 = energy-memory)
14
+ kind: energy-memory
15
+ path: false
16
+ verbose: false
17
+ - name: eshoppen-net # calculates e due to memory util ((mem-util * mem-allocated * mem-energy)/1000 = energy-memory)
18
+ kind: energy-network
19
+ path: false
20
+ verbose: false
21
+ - name: sci-e # sums energy-cpu and energy-memory
22
+ kind: builtin
23
+ path: ''
24
+ verbose: false
25
+ - name: sci-m # a model that calculates m from te, tir, el, rr and rtor
26
+ kind: builtin
27
+ path: ''
28
+ verbose: false
29
+ - name: sci-o # takes in total e and outputs operational emissions
30
+ kind: builtin
31
+ path: ''
32
+ - name: sci # sums SCI components and converts to f.unit
33
+ kind: builtin
34
+ path: ''
35
+ graph:
36
+ children:
37
+ front-end:
38
+ pipeline:
39
+ - eshoppen-cpu # thermal-design-power & cpu -> energy
40
+ - eshoppen-mem # n-hours * n-chips * thermal-design-power-mem * thermal-design-power-coeff
41
+ - sci-m # duration & config -> embodied
42
+ - sci-e # energy & grid-carbon-intensity & embodied -> carbon
43
+ - sci-o # e -> c
44
+ - sci # -> f.unit
45
+ config:
46
+ energy-memory-thermal-design-power:
47
+ n-hours: 1
48
+ n-chips: 1
49
+ thermal-design-power-mem: 12.16
50
+ thermal-design-power-coeff: 0.12
51
+ sci-m:
52
+ total-embodied-emissions: 350000 # kgCO2eq
53
+ time-reserved: 3600 # == the duration field
54
+ expected-lifespan: 126144000 # 4 years in seconds
55
+ resources-reserved: 1
56
+ total-resources: 1
57
+ sci-o:
58
+ grid-carbon-intensity: 951 # gCO2e/kWh
59
+ energy-cpu:
60
+ physical-processor: Intel® Core™ i7-1185G7
61
+ thermal-design-power: 28 # W
62
+ thermal-design-power-coeff: 0.12
63
+ n-hours: 1
64
+ n-chips: 1
65
+ sci:
66
+ functional-unit-duration: 1
67
+ functional-duration-time: ''
68
+ functional-unit: requests # factor to convert per time to per f.unit
69
+ inputs:
70
+ - timestamp: 2023-07-06T00:00 # [KEYWORD] [NO-SUBFIELDS] time when measurement occurred
71
+ duration: 3600 # Secs
72
+ cpu-util: 0
73
+ app-server:
74
+ pipeline: # note: no energy-memory calc applied here
75
+ - eshoppen-cpu # thermal-design-power & cpu -> energy
76
+ - sci-e # sums e components
77
+ - sci-m # duration & config -> embodied
78
+ - sci-o # energy & grid-carbon-intensity & embodied -> carbon
79
+ - sci
80
+ config:
81
+ sci-m:
82
+ total-embodied-emissions: 1205520 # kgCO2eq
83
+ time-reserved: 1 # == duration field
84
+ expected-lifespan: 35040 # 4 years in seconds
85
+ resources-reserved: 2 # using cores
86
+ total-resources: 16 # the original report has a typo, says 16 but actually has 26 cores.
87
+ sci-o:
88
+ grid-carbon-intensity: 951 # gCO2e/kWh
89
+ energy-cpu:
90
+ physical-processor: Intel® Xeon® Platinum 8272CL
91
+ thermal-design-power: 205
92
+ thermal-design-power-coeff: 0.32
93
+ n-hours: 1
94
+ n-chips: 1
95
+ sci:
96
+ functional-unit-duration: 1
97
+ functional-duration-time: ''
98
+ functional-unit: requests # factor to convert per time to per f.unit
99
+ inputs:
100
+ - timestamp: 2023-07-06T00:00 # [KEYWORD] [NO-SUBFIELDS] time when measurement occurred
101
+ duration: 3600
102
+ cpu-util: 18.392
103
+ db-server:
104
+ pipeline: # no energy-memory calc applied here
105
+ - eshoppen-cpu # thermal-design-power & cpu & duration-> energy
106
+ - sci-e # sums e-components
107
+ - sci-m # duration & config -> embodied
108
+ - sci-o # energy & grid-carbon-intensity & embodied -> carbon
109
+ config:
110
+ sci-o:
111
+ grid-carbon-intensity: 1000 # gCO2e/kWh
112
+ sci-m:
113
+ total-embodied-emissions: 1433120 # kgCO2eq
114
+ time-reserved: 1 # == duration field
115
+ expected-lifespan: 35040 # 4 years in hours
116
+ resources-reserved: 2 # using cores
117
+ total-resources: 16 # total cores
118
+ sci-c:
119
+ grid-carbon-intensity: 951
120
+ energy-cpu:
121
+ n-hours: 1
122
+ n-chips: 1
123
+ physical-processor: Intel® Xeon® Platinum 8160
124
+ thermal-design-power: 150 # W
125
+ thermal-design-power-coeff: 0.32
126
+ sci:
127
+ functional-unit-duration: 1
128
+ functional-duration-time: ''
129
+ functional-unit: requests # factor to convert per time to per f.unit
130
+ inputs:
131
+ - timestamp: 2023-07-06T00:00 # [KEYWORD] [NO-SUBFIELDS] time when measurement occurred
132
+ duration: 3600
133
+ cpu-util: 10
134
+ grid-carbon-intensity: 1000
135
+ network:
136
+ pipeline:
137
+ - eshoppen-net
138
+ - sci-e # sums e components
139
+ - sci-m
140
+ - sci-o
141
+ - sci
142
+ config:
143
+ sci-m:
144
+ total-embodied-emissions: 0 # kgCO2eq
145
+ time-reserved: 1 # == duration field
146
+ expected-lifespan: 35040 # 4 years in seconds
147
+ resources-reserved: 1 # using cores
148
+ total-resources: 1 # total cores
149
+ energy-network:
150
+ net-energy: 0.001 #kwh/GB
151
+ sci:
152
+ functional-unit-duration: 1
153
+ functional-duration-time: ''
154
+ functional-unit: requests # factor to convert per time to per f.unit
155
+ sci-o:
156
+ grid-carbon-intensity: 951
157
+ inputs:
158
+ - timestamp: 2023-07-06T00:00
159
+ duration: 3600
160
+ data-in: 1.16
161
+ data-out: 14.3
162
+
@@ -0,0 +1,58 @@
1
+ name: mft-green-ai
2
+ description: "https://github.com/Green-Software-Foundation/sci-guide/blob/dev/use-case-submissions/msft-green-ai.md"
3
+ tags:
4
+ kind: ml
5
+ complexity: simple
6
+ category: cloud
7
+ initialize:
8
+ models:
9
+ - name: sci-o # a model that given e, i and m calculates a carbon value (e * i) + m
10
+ kind: builtin
11
+ verbose: false
12
+ path: ''
13
+ - name: wattime
14
+ kind: builtin
15
+ verbose: false
16
+ path: ''
17
+ - name: sci
18
+ kind: builtin
19
+ verbose: false
20
+ path: ''
21
+ graph:
22
+ DenseNet: # an advanced grouping node
23
+ pipeline:
24
+ - sci-o # energy & grid-carbon-intensity & embodied -> carbon
25
+ - watttime
26
+ - add-obs
27
+ - sci
28
+ config:
29
+ sci-o:
30
+ physical-processor: nvidia-t4-nc16as-v3
31
+ grid-carbon-intensity: 1 # data not provided in case study
32
+ embodied-carbon: 0
33
+ sci:
34
+ functional-unit-duration: '' # signal to convert /s -> /hr
35
+ functional-unit: '' # factor to convert per time to per f.unit ()
36
+ inputs:
37
+ - timestamp: 2023-07-06T00:00
38
+ duration: 1336 # 22.27 min runtime in seconds
39
+ energy: 17.97
40
+ InceptionV3: # an advanced grouping node
41
+ pipeline:
42
+ - sci-o # energy & grid-carbon-intensity & embodied -> carbon
43
+ - watttime
44
+ - add-obs
45
+ - sci
46
+ config:
47
+ sci-o:
48
+ physical-processor: nvidia-t4-nc16as-v3
49
+ grid-carbon-intensity: 1 # data not provided in case study
50
+ embodied-carbon: 0
51
+ sci:
52
+ functional-unit-duration: 1
53
+ functional-duration-time: ''
54
+ functional-unit: requests # factor to convert per time to per f.unit
55
+ inputs:
56
+ - timestamp: 2023-07-06T00:00
57
+ duration: 1205 # 22.27 min runtime in seconds
58
+ energy: 14.37
@@ -0,0 +1,201 @@
1
+ name: ntt-data-on-premise
2
+ description: https://github.com/Green-Software-Foundation/sci-guide/blob/dev/use-case-submissions/nttdatta-On-Premise-Web-system.md
3
+ tags:
4
+ kind: web
5
+ complexity: moderate
6
+ category: on-premise
7
+ initialize:
8
+ models:
9
+ - name: sci-e
10
+ kind: builtin
11
+ verbose: false
12
+ path: ''
13
+ - name: sci-m # a model that calculates m from te, tir, el, rr and rtor
14
+ kind: builtin
15
+ verbose: false
16
+ path: ''
17
+ - name: sci-o # a model that given e, i and m calculates a carbon value (e * i) + m
18
+ kind: builtin
19
+ verbose: false
20
+ path: ''
21
+ - name: sci # a model that given e, i and m calculates a carbon value (e * i) + m
22
+ kind: builtin
23
+ verbose: false
24
+ path: ''
25
+ graph:
26
+ children:
27
+ layer-3-switch: # an advanced grouping node
28
+ pipeline:
29
+ - sci-e
30
+ - sci-m
31
+ - sci-o
32
+ - sci
33
+ config:
34
+ sci-m:
35
+ total-embodied-emissions: 251000 # gCO2eq
36
+ time-reserved: 3600 # 1 hour in s
37
+ expected-lifespan: 126144000 # 4 years in seconds
38
+ resources-reserved: 1
39
+ total-resources: 1
40
+ sci-o:
41
+ grid-carbon-intensity: 457 # gCO2/kwh
42
+ sci:
43
+ functional-unit-duration: 1
44
+ functional-duration-time: ''
45
+ functional-unit: requests # factor to convert per time to per f.unit
46
+ inputs:
47
+ - timestamp: 2023-07-06T00:00
48
+ duration: 3600
49
+ five-min-input-ratotal-embodied-emissions: 100
50
+ five-min-output-ratotal-embodied-emissions: 100
51
+ grid-carbon-intensity: 457 # gCO2e/kWh
52
+ energy-network: 0.00496 # 3.85e-3 * 24 ports * 1.5 (pue)
53
+ requests: 38032740
54
+ layer-2-switch:
55
+ pipeline:
56
+ - sci-e
57
+ - sci-m
58
+ - sci-o
59
+ - sci
60
+ config:
61
+ sci-m:
62
+ total-embodied-emissions: 251000 # gCO2eq
63
+ time-reserved: 3600 # get from the duration field
64
+ expected-lifespan: 126144000 # 4 years in seconds
65
+ resources-reserved: 1
66
+ total-resources: 1
67
+ sci-o:
68
+ grid-ci: 457 # gCO2/kwh
69
+ sci:
70
+ functional-unit-duration: 1
71
+ functional-duration-time: ''
72
+ functional-unit: requests # factor to convert per time to per f.unit
73
+ children:
74
+ switch-1:
75
+ inputs:
76
+ - timestamp: 2023-07-06T00:00
77
+ duration: 1
78
+ energy-network: 0.000811 #kwh
79
+ grid-carbon-intensity: 457 # gCO2e/kWh
80
+ requests: 38032740
81
+ switch-2:
82
+ inputs:
83
+ - timestamp: 2023-07-06T00:00
84
+ duration: 1
85
+ energy-network: 0 # no traffic at all
86
+ grid-carbon-intensity: 457 # gCO2e/kWh
87
+ requests: 38032740
88
+ switch-3:
89
+ inputs:
90
+ - timestamp: 2023-07-06T00:00
91
+ duration: 1
92
+ energy-network: 0.000955 #kwh
93
+ grid-carbon-intensity: 457 # gCO2e/kWh
94
+ requests: 38032740
95
+ switch-4:
96
+ inputs:
97
+ - timestamp: 2023-07-06T00:00
98
+ duration: 1
99
+ energy-network: 1.14e-8 #kwh
100
+ grid-carbon-intensity: 457 # gCO2e/kWh
101
+ requests: 38032740
102
+ db-servers:
103
+ pipeline:
104
+ - sci-e
105
+ - sci-m
106
+ - sci-o
107
+ - sci
108
+ config:
109
+ sci-m:
110
+ total-embodied-emissions: 6270000 # gCO2eq
111
+ time-reserved: duration # get from the duration field
112
+ expected-lifespan: 126144000 # 4 years in seconds
113
+ resources-reserved: 1
114
+ total-resources: 1
115
+ sci-o:
116
+ grid-carbon-intensity: 457 # gCO2/kwh
117
+ sci:
118
+ functional-unit-duration: ''
119
+ functional-unit: requests
120
+ children:
121
+ db-server1:
122
+ inputs:
123
+ - timestamp: 2023-07-06T00:00
124
+ energy-cpu: 0.258
125
+ duration: 1 #s
126
+ grid-carbon-intensity: 457 # gCO2e/kWh
127
+ requests: 38032740
128
+ db-server2:
129
+ inputs:
130
+ - timestamp: 2023-07-06T00:00
131
+ energy-cpu: 0.193
132
+ duration: 1 #s
133
+ grid-carbon-intensity: 457 # gCO2e/kWh
134
+ requests: 38032740
135
+ app-servers:
136
+ pipeline:
137
+ - sci-e
138
+ - sci-m
139
+ - sci-o
140
+ - sci
141
+ config:
142
+ sci-m:
143
+ total-embodied-emissions: 6270000 # gCO2eq
144
+ time-reserved: duration # get from the duration field
145
+ expected-lifespan: 126144000 # 4 years in seconds
146
+ resources-reserved: 1
147
+ total-resources: 1
148
+ sci-o:
149
+ grid-carbon-intensity: 457 # gCO2/kwh
150
+ sci:
151
+ functional-unit-duration: 1
152
+ functional-duration-time: ''
153
+ functional-unit: requests # factor to convert per time to per f.unit
154
+ children:
155
+ app-server1:
156
+ inputs:
157
+ - timestamp: 2023-07-06T00:00
158
+ duration: 1
159
+ energy-cpu: 0.149
160
+ grid-carbon-intensity: 457 # gCO2e/kWh
161
+ app-server2:
162
+ inputs:
163
+ - timestamp: 2023-07-06T00:00
164
+ duration: 1
165
+ energy-cpu: 0.147
166
+ grid-carbon-intensity: 457 # gCO2e/kWh
167
+ requests: 38032740
168
+ web-servers:
169
+ pipeline:
170
+ - sci-e
171
+ - sci-m
172
+ - sci-o
173
+ - sci
174
+ config:
175
+ sci-m:
176
+ total-embodied-emissions: 6270000 # gCO2eq
177
+ time-reserved: duration # get from the duration field
178
+ expected-lifespan: 126144000 # 4 years in seconds
179
+ resources-reserved: 1
180
+ total-resources: 1
181
+ sci-o:
182
+ grid-carbon-intensity: 457 # gCO2/kwh
183
+ sci:
184
+ functional-unit-duration: 1
185
+ functional-duration-time: ''
186
+ functional-unit: requests # factor to convert per time to per f.unit
187
+ children:
188
+ web-server1:
189
+ inputs:
190
+ - timestamp: 2023-07-06T00:00
191
+ duration: 1
192
+ energy-cpu: 0.139
193
+ grid-carbon-intensity: 951 # gCO2e/kWh
194
+ requests: 38032740
195
+ web-server2:
196
+ inputs:
197
+ - timestamp: 2023-07-06T00:00
198
+ duration: 1
199
+ energy-cpu: 0.116
200
+ grid-carbon-intensity: 951 # gCO2e/kWh
201
+ requests: 38032740
@@ -0,0 +1,19 @@
1
+ name: tdp-tester
2
+ initialize:
3
+ models:
4
+ - name: tdp-finder # a model that returns an embodied value given the sci embodied attribution equation.
5
+ kind: builtin
6
+ verbose: false
7
+ path: ''
8
+ graph:
9
+ children:
10
+ backend:
11
+ pipeline:
12
+ - tdp-finder
13
+ config:
14
+ tdp-finder:
15
+ tdp:
16
+ observations:
17
+ - timestamp: 2023-07-06T00:00
18
+ physical-processor: AMD 3020e
19
+
@@ -0,0 +1,26 @@
1
+ name: ccf-demo
2
+ description: example impl invoking CCF model
3
+ tags:
4
+ initialize:
5
+ models:
6
+ - name: azure-importer
7
+ path: if-models
8
+ model: AzureImporterModel
9
+ kind: plugin
10
+ graph:
11
+ children:
12
+ child:
13
+ pipeline:
14
+ - azure-importer
15
+ config:
16
+ azure-importer:
17
+ inputs:
18
+ - timestamp: '2023-11-02T10:35:31.820Z'
19
+ duration: 3600
20
+ azure-observation-window: 5 min # value and unit must be space separated
21
+ azure-observation-aggregation: 'average'
22
+ azure-subscription-id: 9de7e19f-8a18-4e73-9451-45fc74e7d0d3
23
+ azure-resource-group: vm1_group
24
+ azure-vm-name: vm1
25
+
26
+
@@ -0,0 +1,19 @@
1
+ name: ccf-demo
2
+ description: example impl invoking CCF model
3
+ initialize:
4
+ models:
5
+ - name: ccf
6
+ kind: builtin
7
+ graph:
8
+ children:
9
+ child:
10
+ pipeline:
11
+ - ccf
12
+ config:
13
+ ccf:
14
+ vendor: aws
15
+ instance-type: m5n.large
16
+ inputs:
17
+ - timestamp: 2023-07-06T00:00 # [KEYWORD] [NO-SUBFIELDS] time when measurement occurred
18
+ duration: 1
19
+ cpu-util: 10
@@ -0,0 +1,67 @@
1
+ name: gsf-demo-pipeline
2
+ description:
3
+ More complex pipeline example
4
+ tags:
5
+ kind: web
6
+ complexity: moderate
7
+ category: cloud
8
+ initialize:
9
+ models:
10
+ - name: teads-curve
11
+ kind: builtin
12
+ - name: sci-m
13
+ kind: builtin
14
+ - name: sci-o
15
+ kind: builtin
16
+ - name: sci-e
17
+ kind: builtin
18
+ - name: eshoppen-net
19
+ kind: builtin
20
+ - name: eshoppen-mem
21
+ kind: builtin
22
+ - name: eshoppen-cpu
23
+ kind: builtin
24
+ - name: sampler
25
+ kind: shell
26
+ graph:
27
+ children:
28
+ child:
29
+ pipeline:
30
+ - eshoppen-mem
31
+ - eshoppen-cpu
32
+ - eshoppen-net
33
+ - sci-e
34
+ - sci-o
35
+ - sampler
36
+ config:
37
+ teads-curve:
38
+ thermal-design-power: 1
39
+ sampler:
40
+ executable: python3 /usr/local/bin/sampler
41
+ inputs:
42
+ - timestamp: 2023-07-06T00:00 # [KEYWORD] [NO-SUBFIELDS] time when measurement occurred
43
+ processor: Intel® Core™ i7-1185G7
44
+ data-in: 1
45
+ data-out: 1
46
+ net-energy: 1
47
+ n-hours: 1
48
+ n-chips: 1
49
+ tdp-mem: 1
50
+ tdp-coeff: 1
51
+ duration: 3600 # Secs
52
+ thermal-design-power: 28 # W
53
+ cpu-util: 18.392
54
+ grid-carbon-intensity: 951 # gCO2e/kWh
55
+ - timestamp: 2023-08-06T00:00 # [KEYWORD] [NO-SUBFIELDS] time when measurement occurred
56
+ processor: Intel® Core™ i7-1185G7
57
+ data-in: 1
58
+ data-out: 1
59
+ net-energy: 1
60
+ n-hours: 1
61
+ n-chips: 1
62
+ tdp-mem: 1
63
+ tdp-coeff: 1
64
+ duration: 3600 # Secs
65
+ thermal-design-power: 20 # W
66
+ cpu-util: 16
67
+ grid-carbon-intensity: 800 # gCO2e/kWh
@@ -0,0 +1,51 @@
1
+ name: if-demo
2
+ description: demo pipeline
3
+ tags:
4
+ initialize:
5
+ models:
6
+ - name: azure-importer
7
+ kind: builtin
8
+ - name: cloud-instance-metadata
9
+ kind: builtin
10
+ - name: teads-curve
11
+ kind: builtin
12
+ - name: sci-e
13
+ kind: builtin
14
+ - name: sci-o
15
+ kind: builtin
16
+ - name: sci-e
17
+ kind: builtin
18
+ - name: sci-m
19
+ kind: builtin
20
+ - name: sci
21
+ kind: builtin
22
+ graph:
23
+ children:
24
+ child:
25
+ pipeline:
26
+ - azure-importer
27
+ - cloud-instance-metadata
28
+ - teads-curve
29
+ - sci-e
30
+ - sci-o
31
+ - sci-m
32
+ - sci
33
+ config:
34
+ sci:
35
+ functional-unit: ''
36
+ functional-unit-time: hour
37
+ functional-unit-duration: 1
38
+ inputs:
39
+ - timestamp: '2023-11-02T10:35:31.820Z'
40
+ duration: 3600
41
+ azure-observation-window: 5 min # value and unit must be space separated
42
+ azure-observation-aggregation: 'average'
43
+ azure-subscription-id: 9de7e19f-8a18-4e73-9451-45fc74e7d0d3
44
+ azure-resource-group: vm1_group
45
+ azure-vm-name: vm1
46
+ grid-carbon-intensity: 951
47
+ total-embodied-emissions: 1533.12
48
+ time-reserved: 300
49
+ expected-lifespan: 94348800 # 3 yrs in seconds
50
+ resources-reserved: 1
51
+ total-resources: 64
@@ -0,0 +1,20 @@
1
+ name: sci-m
2
+ description: simple demo invoking metadata lookup
3
+ tags: null
4
+ initialize:
5
+ models:
6
+ - name: cloud-instance-metadata
7
+ kind: builtin
8
+ graph:
9
+ children:
10
+ child:
11
+ pipeline:
12
+ - cloud-instance-metadata
13
+ config:
14
+ cloud-instance-metadata:
15
+ inputs:
16
+ - timestamp: 2023-07-06T00:00
17
+ duration: 3600
18
+ cloud-vendor: 'azure'
19
+ cloud-instance-type: 'Standard_NC24s_v3'
20
+
@@ -0,0 +1,65 @@
1
+ name: nesting-demo
2
+ description:
3
+ tags:
4
+ kind: web
5
+ complexity: moderate
6
+ category: on-premise
7
+ initialize:
8
+ models:
9
+ - name: teads-curve
10
+ kind: builtin
11
+ - name: sci-e
12
+ kind: builtin
13
+ verbose: false
14
+ path: ''
15
+ - name: sci-m
16
+ kind: builtin
17
+ verbose: false
18
+ path: ''
19
+ - name: sci-o
20
+ kind: builtin
21
+ verbose: false
22
+ path: ''
23
+ - name: sci
24
+ kind: builtin
25
+ verbose: false
26
+ path: ''
27
+ graph:
28
+ children:
29
+ child: # an advanced grouping node
30
+ pipeline:
31
+ - teads-curve
32
+ - sci-e
33
+ - sci-m
34
+ - sci-o
35
+ - sci
36
+ config:
37
+ teads-curve:
38
+ thermal-design-power: 65
39
+ sci-m:
40
+ total-embodied-emissions: 251000 # gCO2eq
41
+ time-reserved: 3600 # 1 hour in s
42
+ expected-lifespan: 126144000 # 4 years in seconds
43
+ resources-reserved: 1
44
+ total-resources: 1
45
+ sci-o:
46
+ grid-carbon-intensity: 457 # gCO2/kwh
47
+ sci:
48
+ functional-unit-duration: 1
49
+ functional-duration-time: ''
50
+ functional-unit: requests # factor to convert per time to per f.unit
51
+ children:
52
+ child-1:
53
+ inputs:
54
+ - timestamp: 2023-07-06T00:00
55
+ duration: 10
56
+ cpu-util: 50
57
+ e-net: 0.000811 #kwh
58
+ requests: 380
59
+ child-2:
60
+ inputs:
61
+ - timestamp: 2023-07-06T00:00
62
+ duration: 10
63
+ cpu-util: 33
64
+ e-net: 0.000811 #kwh
65
+ requests: 380