Closed magv closed 3 years ago
Thanks for your suggestion!
How about the MIT license? If this is fine, then I will add the license declaration to the beginning of formset.py
such that you can pick this file up for your project.
I'm happy with rewriting main
function and split search
from it. It will be nice if you can make a pull request for it. Perhaps it would be more favourable to define search
as
def search(setup, total_memory):
# type: (Setup, float) -> Tuple[Setup, float]
"""Search for the optimized setup parameters for the given memory amount."""
...
in such a way that this function returns a set of optimized setup parameters and also its actual memory usage. (I guess they are needed for the main
function, though I don't remember the details.)
As you can see in .pre-commit-config.yaml
, this repository uses pre-commit
for lining: black
, flake8
, mypy
and gitlint
. To set up this, you need to install pre-commit
and
pre-commit install
pre-commit install --hook-type commit-msg
To run the linters:
pre-commit run --all-files
The git commit message should use the Conventional Commits, for example,
refactor: split a search function from the main routine
MIT sounds great. I'll prepare a pull request with search()
in a while. The search()
above is not doing 100% the same thing main()
does, but the difference is minor, and I'll try to remove it (once I'll remember what it was :) ).
The license declaration has been added. There were also some changes in formset.py
for tweaking the linter settings (the assert statements were removed).
Hi, Takahiro. I'd like to start using formset.py in pySecDec to generate
form.set
automatically. To this end, I'd like to have your permission, so could you choose a license for it?Also, currently the parts of the code that search for the optimal parameters are in
main()
; I'd like to factorize them so that formset.py could be used a library. For the moment I'm doing this:If you're interested, I can rewrite
main()
to usesearch()
and submit a pull request or something. I'd prefer not to diverge from your code.