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

Setup publiopti #1697

Merged
merged 25 commits into from
Feb 27, 2023
Merged

Setup publiopti #1697

merged 25 commits into from
Feb 27, 2023

Conversation

EmileRolley
Copy link
Contributor

@EmileRolley EmileRolley commented Feb 2, 2023

Setup the model optimisation with publiopti achieving a ~65% reduction in the number of rules.

Remarks

When working on the rules optimisation, I discovered empty rules inside the base model such as pétrole or logement . gaz. Deleting them doesn't seem to be a problem for the simulation.
As full rules are loaded to render documentation page, it isn't an issue to remove them from the optimized model, right? @Clemog

Changelog

  • No standalone somme mechanisms in the empreinte nationale.yaml file.
  • icone -> icônes in alimentation.yaml
  • New predicate keeping specified empty rules and ones which contains the icônes attribute from the optimisation.
  • Upgrade publicodes to the 1.0.0-beta.66 version.
  • First pass of refactoring for the rulesToJSON script -- closes Documenter et refactorer rulesToJSON script #1716.
  • Support optimisation for localized models.
  • Add yarn test:optim to compare personas results between the optim and the base model.

@github-actions
Copy link

github-actions bot commented Feb 2, 2023

Report for the pull request #1697

🚀 Test the model from the website: https://nosgestesclimat.fr?PR=1697


🔧 Model compilation status

Task Status Message
Supported regions ✔️ Ø
Rules evaluation ✔️ Ø
Rules compilation to JSON for the region FR in en-us ✔️ Ø
Rules compression for the region FR in en-us ✔️ Ø
Rules compilation to JSON for the region CH in en-us ✔️ Ø
Rules compression for the region CH in en-us ✔️ Ø
Rules compilation to JSON for the region GP in en-us ✔️ Ø
Rules compression for the region GP in en-us ✔️ Ø
Rules compilation to JSON for the region FR in fr ✔️ Ø
Rules compression for the region FR in fr ✔️ Ø
Rules compilation to JSON for the region CH in fr ✔️ Ø
Rules compression for the region CH in fr ✔️ Ø
Rules compilation to JSON for the region GP in fr ✔️ Ø
Rules compression for the region GP in fr ✔️ Ø
Personas compilation to JSON for fr ✔️ Ø
Personas compilation to JSON for en-us ✔️ Ø
Documentation compilation to JSON ✔️ Ø

🌐 Translation status

Rules

Language Nb. missing translations Status
en-us Ø ✔️

Personas

Language Nb. missing translations Status
en-us Ø ✔️

You will find more information about the translation in the dedicated file.


👫 Personas changes

Test personas regression

Persona Total PR (kg CO2e) Total in prod. (kg CO2e) Δ (%)

Test model optimisation

Persona Total PR with optim. (kg CO2e) Total PR without optim. (kg CO2e) Δ (%)

@EmileRolley EmileRolley force-pushed the fix-optim branch 7 times, most recently from b8c6f3f to 7fe2fe2 Compare February 6, 2023 11:46
@EmileRolley EmileRolley changed the title fix(pkg): upgrade to publiopti@0.1.18 fix(pkg): upgrade to publiopti@latest Feb 13, 2023
@EmileRolley EmileRolley linked an issue Feb 14, 2023 that may be closed by this pull request
8 tasks
@EmileRolley EmileRolley force-pushed the fix-optim branch 2 times, most recently from 3280333 to 1772c39 Compare February 14, 2023 12:01
@EmileRolley EmileRolley changed the title fix(pkg): upgrade to publiopti@latest Setup publiopti Feb 14, 2023
@EmileRolley EmileRolley force-pushed the fix-optim branch 2 times, most recently from f0b02d0 to cc60df5 Compare February 15, 2023 18:00
@laem
Copy link
Contributor

laem commented Feb 21, 2023

@EmileRolley what kind of review do you need from me, if any ?

@EmileRolley
Copy link
Contributor Author

@EmileRolley what kind of review do you need from me, if any ?

A basic code review I think, and some checks on the preview to make sure I haven't forgotten any rules.

@EmileRolley EmileRolley merged commit 346ce80 into master Feb 27, 2023
@EmileRolley EmileRolley deleted the fix-optim branch February 27, 2023 17:35
EmileRolley added a commit to incubateur-ademe/nosgestesclimat-site that referenced this pull request Feb 27, 2023
Feat: activation de l'optimisation du modèle avec publiopti follows incubateur-ademe/nosgestesclimat#1697
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Documenter et refactorer rulesToJSON script Use the new compression tool to generate optimized models
3 participants