All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.
0.9.2 - 2024-10-01
energy
,gradient
,hessian
, andoptimization
support the theCRESTAdapter
.
0.9.1 - 2024-09-12
CalcType.optimization
support for TeraChem.typos
pre-commit check.
0.9.0 - 2024-09-11
- 🚨: Bumped minimum python version from 3.8 -> 3.9 (needed for compatibility with
tcpb
). - Updated type annotations to use
dict
,list
,tuple
instead oftyping.Dict
, etc.
black
andisort
in favor of modernruff
.
- TeraChem protocol buffer server (and frontend) adapters.
0.8.1 - 2024-08-13
CRESTAdapter
that supportsCalcType.conformer_search
.mkdocs
documentation.
0.8.0 - 2024-07-19
- Updated to qcio 0.11.0 which removed
NoResults
and requires explicit passing of a.results
value toProgramOutput
rather than implicitly passingNone
and havingqcio
set.results = NoResult
. It also moved.files
fromProgramOutput
to theresults
objects.
0.7.5 - 2024-07-17
- Only respect
collect_file
for forAdapter.compute
if the adapter has.uses_files=True
. - Moved the
program_version = self.program_version(stdout)
call fromBaseAdapter.compute(...)
to outside thetry
block so that program version is collected even if the calculation fails. - Cleaned up
xtb
cached version implementation. - Added
confirm_version
check torelease.py
.
0.7.4 - 2024-07-16
- Added
threading.Lock()
tocapture_sys_stdout
so that it is thread safe. - Cached
XTBAdapter.program_version
result since calls toimportlib.metadata.version(...)
callos.listdir()
and when doing very manyxtb
calls these became substantial (almost 1/2 the execution time). We have to useimportlib.metadata.version
rather thanxtb.__version__
directly because their__version__
string is wrong.
0.7.3 - 2024-07-12
release.py
script for automated releases.
- Upgraded to
qcio 0.10.2
which reverts back to the default ofStructure.identifiers
instead ofStructure.ids
. - Fix depreciated call to
qcparse.parse_results
for the TeraChem adapter.
0.7.2 - 2024-07-12
-
xtb
to optional installs and error message forXtbAdapter
to indicate it can be installed withpip install qcop[xtb]
. -
qcop.adapters.utils.set_env_variable
context manager to address the fact that one must set the env varOMP_NUM_THREADS=1
before importing any of thextb
library or else performance is severely impacted (around 10x). They spawn threads within threads so if you leave the default value (which is the number of cores on your machine) you get way more threads than this! E.g., on my 16 core machine I'll get 47 threads spawned for a single calculation. If I set this to1
I actually get the correct number of threads, which is16
. One must set this value before importing any piece of thextb
library, so if your script imports anything fromxtb
before callingqcop.compute("xtb", ...)
wrap this import with theqcop.adapters.utils.set_env_variable
wrapper like this:from qcop.adapters.utils import set_env_variable with set_env_variable("OMP_NUM_THREADS", "1"): import xtb import xtb.interface import xtb.libxtb from xtb.utils import Solvent ### The rest of your script
0.7.1 - 2024-07-10
- Incorrect check in
BaseAdapter.compute()
usingisinstance(inp_obj, FileInput)
. Updated totype(inp_obj) is FileInput
to work with updatedqcio
inheritance hierarchy.
0.7.0 - 2024-07-10
- Added validation check for programs that do not support file inputs if files are passed as an input.
- 🚨 Updated to
qcio 0.10.1
which usesStructure
in place ofMolecule
. - Changed
Adapter.write_files
toAdapter.uses_files
to more clearly define purpose of this variable. tmpdir
context manager only creates a temporary directory ifmkdir
is passed as the first argument. This works in conjunction withAdapter.uses_files
so that adapters that do not use file I/O (e.g., pure Python programs) do not have the additional overhead of creating and removing temporary directories for their calculations.
0.6.2 - 2024-06-13
try/except
to top-levelcompute
function that will append the.program_output
to the exception if theget_adapter
function raises an exception.
- Modified exception hierarchy to include fewer
**kwarg
arguments, use mostlyargs
instead, and fixed issue where some exceptions still didn't have.program_output
set on them.
0.6.1 - 2024-06-10
*args
and**kwargs
passing to parent classes inAdapterError
and subclasses to fix celery serialization issues in BigChem.
- 🚨 Changed
compute
kwargcollect_wavefunction
tocollect_wfn
to matchBaseAdapter
nomenclature. (Cheating in this breaking change since I don't think this feature is used by outsiders yet...)
0.6.0 - 2024-04-23
- Fixed all mypy errors that were previously not raised because
qcio
did not contain apy.types
file.
- Updated to latest
qcio
data structures eliminatingSinglePointOutput
,OptimizationOutput
, andProgramFailure
in favor of a GenericProgramOutput
object. Backwards compatibility is maintained byqcio
so that oldSinglePointOutput
,OptimizationOutput
, andProgramFailure
objects are still accepted in end user code withFutureWarning
messages. BaseAdapter
is generic overInputType
andResultsType
.ProgramAdapter
is generic overStructuredInputType
andResultsType
.- Adapters now inherit from these Generic classes and specify compatible types explicitly.
- Updated examples and tests to reflect the new
qcio
data structures nomenclature, emphasizingpi
forProgramInput
andpo
forProgramOutput
objects.
0.5.5 - 2024-04-12
AttributeError
check tocapture_sys_stdout
so that when running inside celery andsys.stdout
isLoggingProxy
object, we can still capture the stdout correctly.
0.5.4 - 2024-04-12
try/finally
blocks totmpdir
context managers to ensure that temporary directories are always cleaned up and the originalcwd
is restored, even if an exception is raised.- Properly capture
qcparse
encoder/parser exceptions inTeraChemAdapter
and raiseqcop.AdapterInputError
.
- Moved
self.validate_input(inp_obj)
,self.program_version(stdout)
, andself.collect_wfn(...)
inside oftry/except
block inBaseAdapter.compute()
. This is more correct by catching all possible qcop exceptions and returning aProgramFailure
object on the raised exception. This helps eliminate 500 errors in ChemCloud when a user passes an invalid input object to a program adapter or requests a wavefunction from a program that doesn't support it. - Redefined signature to
collect_wfn
tocollect_wfn() -> Dict[str: Union[str, bytes]]
so that it can run before constructing theProgramFailure
object inBaseAdapter.compute()
.
0.5.3 - 2024-04-11
capture_sys_stdout
context manager to capturestdout
from non-python libraries (e.g., C/C++). This is necessary for processes that do not write to Python'ssys.stdout
object, such asxtb
.xtb
to developer dependencies and axtb
tests to the test suite.
xtb
does not close file handles correctly so we'd getOSError: [Errno 24] Too many open files
after running a few hundred jobs.XTBAdapter
now uses the newcapture_sys_stdout
context manager to capturestdout
.xtb.program_version
now returnsimportlib.metadata('xtb')
becausextb
incorrectly hardcodes the version in the__init__.py
file. Issue here.
0.5.2 - 2024-04-10
- Added
xtb
adapter.qcengine.get_program
adds almost >1 second of overhead to each call, which makesxtb
unusable viaqcengine
since a singlextb
execution make take only ~0.003 seconds.
0.5.1 - 2024-03-29
- Upgraded to
qcio>=0.8.1
to fix QCElemental behavior that auto-rotates Structures without user consent. - Modified all example scripts to be standalone without referencing an external
.xyz
file and to usetry/except
statements now thatraise_exc=True
is the default.
py.typed
file to enable type checking in other projects that useqcop
.
0.5.0 - 2024-03-16
- Changed default
compute
behavior toraise_exc=True
instead ofraise_exc=False
.
- Non operational placeholder
psi4
integration test.
0.4.8 - 2024-01-12
GeometricError
toqcop.exceptions
module. Without this whengeometric
raised an exception it wouldn't be caught by theexcept QCOPBaseError
block inadapter.compute()
and theProgramFailure
object wouldn't be returned to the user. This fixes a 500 error in ChemCloud Server whengeometric
fails to converge and raises an exception (ageometric
exception) that isn't found by the server.
QCEngineError
now a subclass ofExternalProgramError
instead ofQCOPBaseError
.ExternalProgramExecutionError
renamed toExternalSubprocessError
to better reflect its purpose.
0.4.7 - 2023-09-27
- Removed TeraChem input file encoding as this was refactored to the
qcparse
library. - Updated
qcparse
dependency from>=0.5.1
to>=0.5.2
to support the new encoding API. - Updated
qcio
dependency to reflect the same minimum version asqcparse
.
0.4.6 - 2023-09-22
adapter.collect_wfn()
now raisesAdapterInputError
rather thanNotImplementedError
ifpropagate_wfn=True
is passed. This change allows these errors to be captured by theexcept QCOPBaseError as e:
block inadapter.compute()
so that theProgramFailure
object can be returned to the user. This fixes a 500 error in ChemCloud Server when a user passespropagate_wfn=True
to a program that doesn't support it.
0.4.5 - 2023-09-19
README.md
documentation.
- Dropped Python version from
^3.8.1
to3.8
. - Updated
qcparse
dependency from>=0.5.0
to>=0.5.1
to support Python^3.8
change.
0.4.4 - 2023-09-08
- Added
ProgramFailure
object toexception.args
inBaseAdapter.compute()
method so that Celery will correctly serialize the object and pass theexception.program_failure
object from workers to clients.
- Updated
qcio
from>=0.5.0
to>=0.6.0
. - Dropped multiple inheritance on
ExternalProgramExecutionError
by removingCalledProcessError
. Retained the original attributes.
0.4.3 - 2023-09-03
- Extras specification in pyproject.toml so that
qcengine
,qcelemental
, andgeometric
don't get installed by default but may be optionally installed if compatibility is desired.
0.4.2 - 2023-09-02
- TeraChem adapter was writing
CalcType.energy
instead ofenergy
forruntype
intc.in
file.
0.4.1 - 2023-09-02
- Added a
ProgramFailure
object to all program related exceptions raised byadapter.compute()
. Now every exception returned from.compute()
will have the full traceback context and provenance data for error handling. Very helpful so that BigChem can operate on araise_exc=True
paradigm to take advantage of python standard failure/retry logic based on exceptions but still return the entireProgramFailure
object for returning to end users via ChemCloud.
stdout
now gets correctly added toProgramFailure
object.
0.4.0 - 2023-08-31
- Updated pydantic from
v1
->v2
.
0.3.2 - 2023-08-18
GeometricEngine
now appends all computed trajectory results to the raised exception if subprogram crashes so a user can inspect the failed results.
0.3.1 - 2023-07-19
- Tiny bug in
ensure_geometric
test.
0.3.0 - 2023-07-19
GeometricAdapter
- Added
.collect_wfn
and.propagate_wfn
methods to adapters to facilitate wavefunction passing for sequential program adapters--like geomeTRIC.
- Refactored top level
main.compute()
function to mostly live inBaseAdapter.compute()
. This makes consumption of adapters by dual program adapters, likeGeometricAdapter
, much cleaner.
0.2.0 - 2023-07-17
- Updated to flattened
qcio v0.3.0
data models. - Changed order of args to
compute()
to allow for the same pattern tocompute_args
.
0.1.0 - 2023-06-29
- Core compute capabilities exposed in top-level
compute()
function, includingQCEngine
fallback for programs without aqcop
adapter. - Created adapter for TeraChem.
- Exposed general purpose computing for any subprocess with
FileAdaptor