Basis optimization CLI
Here is the PR with the basis optimization CLI.
Probably I should add something to the documentation.
@zerothi could you test if it works fine for you? You just need to have the inputs for a calculation in a directory and then run:
stoolbox basis optim --geometry file.fdf
The only constraint is that the fdf file can't be named RUN.fdf.
EDIT: If you want to optimize with BADS (the default optimizer) you just need to install pybads:
pip install pybads
Seems like we should move the basis optim writer to the _yaml_reader and rename it.
@pfebrer could you please review my comments, then we should get it in asap (note I forced pushed a rebase!)
Hey, I have answered them, sorry I think I was too busy when I saw the review
Codecov Report
Attention: Patch coverage is 22.09302% with 67 lines in your changes missing coverage. Please review.
Project coverage is 86.82%. Comparing base (
58d60d8) to head (ec336e9). Report is 2 commits behind head on main.
| Files with missing lines | Patch % | Lines |
|---|---|---|
| src/sisl/_lib/_argparse.py | 22.61% | 65 Missing :warning: |
| src/sisl/_core/periodictable.py | 0.00% | 2 Missing :warning: |
Additional details and impacted files
@@ Coverage Diff @@
## main #910 +/- ##
==========================================
- Coverage 86.92% 86.82% -0.10%
==========================================
Files 412 412
Lines 54332 54413 +81
==========================================
+ Hits 47227 47244 +17
- Misses 7105 7169 +64
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
:rocket: New features to boost your workflow:
- :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
I have some questions, the charge-confinement scheme is not only targeted polarization orbitals. AFAIK, it's use is for non-populated orbitals, and so could be either regular empty orbitals or something else.
I will also add the soft-confinement to play with. Do you have any comments on this before I make changes?
@pfebrer could you have a look at the latest commit I made, I added soft-confinement, and changed the logic of the charge-confinement (now for q=0 orbitals + polarization orbitals).
Plus some other minor details.
Regarding the charge confinement and soft-confinement, the basis optimization follows a workflow that Federico determined was general and good enough to optimize the basis in "any" system. So it was not meant to be very flexible in what you can optimize, but that was more a feature than a bug I would say. If you want to change something about the workflow, I would talk to Federico