fitter
fitter copied to clipboard
Quality-of-Life Improvements: PEP 8 Standards and NumPy 2.0 Compatibility
I've made several quality-of-life improvements to this repository while preserving the core functionality created by the original author. Changes include implementing PEP 8 formatting standards, adding NumPy 2.0 compatibility, restructuring imports for better readability, and enhancing error handling.
python3 run_tests.py -v
Using project root: /Users/james/Desktop/fitter
Added src directory to Python path: /Users/james/Desktop/fitter/src
Discovering tests in directory '.' with pattern 'test_*.py'...
Found 3 test files
- ./test_histfit.py
- ./test_fitter.py
- ./test_main.py
Running tests with pytest...
Added src directory to PYTHONPATH: /Users/james/Desktop/fitter/src
Running command: /Library/Frameworks/Python.framework/Versions/3.13/bin/python3 -m pytest -v ./test_histfit.py ./test_fitter.py ./test_main.py
========================================================================== test session starts ===========================================================================
platform darwin -- Python 3.13.2, pytest-8.3.5, pluggy-1.5.0 -- /Library/Frameworks/Python.framework/Versions/3.13/bin/python3
cachedir: .pytest_cache
rootdir: /Users/james/Desktop/fitter
configfile: pyproject.toml
collected 8 items
test_histfit.py::test1 PASSED [ 12%]
test_histfit.py::test2 PASSED [ 25%]
test_fitter.py::test_dist PASSED [ 37%]
test_fitter.py::test_fitter PASSED [ 50%]
test_fitter.py::test_gamma PASSED [ 62%]
test_fitter.py::test_others PASSED [ 75%]
test_fitter.py::test_n_jobs_api PASSED [ 87%]
test_main.py::test_main_app PASSED [100%]
============================================================================ warnings summary ============================================================================
test/test_fitter.py::test_fitter
test/test_fitter.py::test_fitter
test/test_fitter.py::test_fitter
test/test_fitter.py::test_fitter
test/test_fitter.py::test_fitter
test/test_fitter.py::test_fitter
test/test_fitter.py::test_fitter
test/test_fitter.py::test_fitter
test/test_fitter.py::test_fitter
/Library/Frameworks/Python.framework/Versions/3.13/lib/python3.13/site-packages/joblib/externals/loky/backend/fork_exec.py:38: DeprecationWarning: This process (pid=11293) is multi-threaded, use of fork() may lead to deadlocks in the child.
pid = os.fork()
-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
===================================================================== 8 passed, 9 warnings in 8.00s ======================================================================
Test run completed in 9.18 seconds