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

feat(pid-lagrange, test): add algo and update test #210

Merged
merged 23 commits into from
Apr 13, 2023

Conversation

Gaiejj
Copy link
Member

@Gaiejj Gaiejj commented Apr 11, 2023

Description

  1. feat(pid-lagrange): support pid lagrange
  2. style(test): update tests files

Types of changes

What types of changes does your code introduce? Put an x in all the boxes that apply:

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds core functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation (update in the documentation)

Checklist

Go over all the following points, and put an x in all the boxes that apply.
If you are unsure about any of these, don't hesitate to ask. We are here to help!

  • I have read the CONTRIBUTION guide. (required)
  • My change requires a change to the documentation.
  • I have updated the tests accordingly. (required for a bug fix or a new feature)
  • I have updated the documentation accordingly.
  • I have reformatted the code using make format. (required)
  • I have checked the code using make lint. (required)
  • I have ensured make test pass. (required)

@codecov-commenter
Copy link

codecov-commenter commented Apr 11, 2023

Codecov Report

Merging #210 (84eb26f) into dev (37fef58) will increase coverage by 6.80%.
The diff coverage is 97.42%.

❗ Current head 84eb26f differs from pull request most recent head 4c0c00e. Consider uploading reports for the commit 4c0c00e to get more accurate results

📣 This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more

@@            Coverage Diff             @@
##              dev     #210      +/-   ##
==========================================
+ Coverage   88.61%   95.41%   +6.80%     
==========================================
  Files          90       98       +8     
  Lines        4444     4323     -121     
==========================================
+ Hits         3938     4125     +187     
+ Misses        506      198     -308     
Impacted Files Coverage Δ
omnisafe/adapter/simmer_adapter.py 100.00% <ø> (+3.57%) ⬆️
omnisafe/algorithms/__init__.py 100.00% <ø> (ø)
omnisafe/algorithms/registry.py 96.29% <ø> (+15.04%) ⬆️
omnisafe/common/simmer_agent.py 100.00% <ø> (+11.47%) ⬆️
omnisafe/evaluator.py 94.28% <ø> (+33.66%) ⬆️
omnisafe/utils/distributed.py 92.78% <ø> (+10.25%) ⬆️
omnisafe/utils/math.py 97.14% <ø> (+21.05%) ⬆️
omnisafe/utils/model.py 100.00% <ø> (+18.42%) ⬆️
omnisafe/utils/plotter.py 91.22% <50.00%> (+18.15%) ⬆️
omnisafe/utils/command_app.py 77.41% <87.50%> (+11.90%) ⬆️
... and 20 more

... and 19 files with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@Gaiejj Gaiejj changed the title feat(pid-lagrange): support pid lagrange feat(pid-lagrange, test): add algo and update test Apr 12, 2023
@Gaiejj Gaiejj marked this pull request as ready for review April 12, 2023 05:35
@Gaiejj Gaiejj requested review from rockmagma02, zmsn-2077 and muchvo and removed request for zmsn-2077 April 12, 2023 05:36
omnisafe/evaluator.py Outdated Show resolved Hide resolved
Copy link
Member

@zmsn-2077 zmsn-2077 left a comment

Choose a reason for hiding this comment

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

.

@@ -61,7 +61,7 @@
parser.add_argument(
'--vector-env-nums',
type=int,
default=2,
default=1,
Copy link
Member Author

Choose a reason for hiding this comment

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

The default value of vector-env-nums needs to be 1 because the early-terminated algorithms does not support vector environments. The original default value 2 will trigger error, so we set 1 instead.

Copy link
Member

@zmsn-2077 zmsn-2077 left a comment

Choose a reason for hiding this comment

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

LGTM.

omnisafe/utils/plotter.py Outdated Show resolved Hide resolved
tests/test_utils.py Outdated Show resolved Hide resolved
Copy link
Collaborator

@muchvo muchvo left a comment

Choose a reason for hiding this comment

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

LGTM.

@Gaiejj Gaiejj merged commit bc91d71 into PKU-Alignment:dev Apr 13, 2023
@Gaiejj Gaiejj deleted the dev-pid branch April 28, 2023 09:01
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.

4 participants