Comments (7)
@loriab's suggested change seems like it would work. Looks like the relevant code is here. Could you give it a shot?
from qcelemental.
Yup, that did it!
from qcelemental.
Awesome, please do make a PR to get this in.
from qcelemental.
maybe:
if expected.dtype == np.complex:
dtype = np.complex
else:
dtype = np.float
xptd, cptd = np.array(expected, dtype=dtype), np.array(computed, dtype=dtype)
something like that should both better handle complex case and still do the expected coercion.
from qcelemental.
Note that with #85, provided one has msgpack
installed (which we could make a req'd dep for psi4, while staying optional for qcel), all numpy arrays stay as their native type upon serialization, so complex should be fine and not a json repr issue needing addressing here or in pydantic.
from qcelemental.
I reply a bit late. I have updated QCElemental to v0.6.1 and installed MsgPack in my dev environment. I still see the ComplexWarning
, is there something more I should do on my end?
from qcelemental.
@loriab any additional hints on how to fix this?
from qcelemental.
Related Issues (20)
- Unsuccessful atom mapping attempts HOT 4
- Add a citation file? HOT 3
- Tests don't find py3Dmol HOT 4
- Accesing qc.models.Molecule.show() HOT 7
- Setup qcel.models.Molecule with non-contiguous fragments HOT 5
- Make basis set optional in WavefunctionProperties
- Molecule declares extras dictionary as Dict[str, Any] but value can be None
- PubChem test fails HOT 1
- BaseSettings has moved to a new package pydantic-settings HOT 5
- qcelemental does not build with Python 3.12 HOT 3
- Include extras in get_hash function of Molecule
- Floating point number allowed for molecular charge but not molecular multiplicity HOT 1
- Links to changelogs in releases don't work HOT 2
- PSA: Pydantic v1/v2 and the QCArchive + Psi4 stack HOT 5
- Floating-point precision error in calculating angles HOT 1
- Molecule representation should include charge and multiplicity HOT 1
- Class inheritance diagram not rendering
- Inconsistent dependency versions for pint and numpy HOT 1
- Change Default Behavior of "fix_com" and "fix_orientation" HOT 6
- PSA: pubchem loose (name_type=word) searches failing HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from qcelemental.