Fix warnings in ci#314
Merged
leeping merged 20 commits intoleeping:masterfrom Mar 7, 2026
Merged
Conversation
_Multiprocessor.run() uses multiprocessing.Manager() + Process() to run each calculation task in a subprocess. When called from the Dask worker thread pool (which runs Tornado's async event loop), fork() on Python 3.9/3.10 inherits locked mutexes from sibling threads and deadlocks. The server then crashes after accepting the first job submission, causing ConnectionRefusedError on the next client poll. Setting openff.evaluator._called_from_test = True in run_server.py activates the existing bypass path in _Multiprocessor.run() that calls the function directly in the current thread instead of spawning a subprocess. This is the mechanism the evaluator itself uses for CI. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
lilyminium
commented
Mar 5, 2026
| # Opt2 = optimize.fmin_bfgs(HYP.compute_val,-xkd,fprime=HYP.compute_grad,gtol=1e-5*np.sqrt(len(dx0)),full_output=True,disp=1) | ||
| # Opt2 = optimize.fmin_l_bfgs_b(HYP.compute_val,-xkd,fprime=HYP.compute_grad,m=30,factr=1e7,pgtol=1e-4,iprint=0,disp=1,maxfun=1e5,maxiter=1e5) | ||
| Opt2 = optimize.fmin_l_bfgs_b(HYP.compute_val,-xkd,fprime=HYP.compute_grad,m=30,factr=1e7,pgtol=1e-4,iprint=-1,disp=0,maxfun=1e5,maxiter=1e5) | ||
| Opt2 = optimize.fmin_l_bfgs_b(HYP.compute_val,-xkd,fprime=HYP.compute_grad,m=30,factr=1e7,pgtol=1e-4,maxfun=int(1e5),maxiter=int(1e5)) |
Collaborator
Author
There was a problem hiding this comment.
To handle the below:
DeprecationWarning: scipy.optimize: The
dispand
iprintoptions of the L-BFGS-B solver are deprecated and will be removed in SciPy 1.18.0.
Opt1 = optimize.fmin_l_bfgs_b(HYP.compute_val,dx0,fprime=HYP.compute_grad,m=30,factr=1e7,pgtol=1e-4,iprint=-1,disp=0,maxfun=1e5,maxiter=1e5)
From the scipy docs, disp and iprint used to control printing:
disp: None or int
Deprecated option that previously controlled the text printed on the screen during the problem solution. Now the code does not emit any output and this keyword has no function.
iprint: int, optional
Deprecated option that previously controlled the text printed on the screen during the problem solution. Now the code does not emit any output and this keyword has no function
lilyminium
commented
Mar 5, 2026
Comment on lines
+609
to
+617
| \\[ = {W_E}\\left[ {\\frac{{{\\sum\\limits_{i \\in {N_s}} | ||
| {{w_i}{{\\left( {E_i^{MM} - E_i^{QM}} | ||
| - \\left( {{{\\bar E}^{MM}} - {{\\bar E}^{QM}}} \\right) \\right)}^2}}}}} | ||
| {{\\sum\\limits_{i \\in {N_s}} {{w_i}{{\\left( | ||
| {E_i^{QM} - {{\\bar E}^{QM}}} \\right)}^2}} }}} \\right] + | ||
| {W_F}\\left[ {\\frac{{\\sum\\limits_{i \\in {N_s}} {{w_i}\\sum\\limits_{a \\in {N_a}} | ||
| {{{\\left| {{\\bf{F}}_{i,a}^{MM} - {\\bf{F}}_{i,a}^{QM}} \\right|}^2}} } }} | ||
| {{\\sum\\limits_{i \\in {N_s}} {{w_i}\\sum\\limits_{a \\in {N_a}} | ||
| {{{\\left| {{\\bf{F}}_{i,a}^{QM}} \\right|}^2}} } }}} \\right]\\] |
Collaborator
Author
There was a problem hiding this comment.
This just needed more escaping of the latex code -- I didn't use a raw string here because it's in the middle of a longer docstring
leeping
approved these changes
Mar 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Outdated strings and imports are causing a ton of warnings in CI -- this PR fixes them.
Most of the changes are changing strings to raw strings. This is rebased off of #312 -- only the most recent commit is relevant.
e.g. the below from a run in
master: