Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gaussian Input format #317

Closed
howlfwq opened this issue Jun 14, 2022 · 10 comments
Closed

Gaussian Input format #317

howlfwq opened this issue Jun 14, 2022 · 10 comments

Comments

@howlfwq
Copy link

howlfwq commented Jun 14, 2022

  1. The default computational method is wb97X-D/6-311++G(d,p). How can I change it to some semi-empirical methods?
  2. Also the default command has "SCF=(XQC, MaxConventionalCycles=300) nosymm Force=NoStep Int(Grid=UltraFine)'. Can I modify it? I have installed the dev version. I couldn't find the right place to edit the source code.
  3. The limit of n_workers for torsion driver is 4. So the maximum number of gaussian jobs submitted for the torsion scan is 4. How do I change the limit to a bigger number?
    Sorry, I have been trying reading your python script. It's a bit hard for me to understand.
@jthorton
Copy link
Contributor

Hi @howlfwq thanks for the issue hopefully the points below help to answer your questions!

  1. To change the QM method you will need to make a config file either via python or using the CLI, from the CLI you can do qubekit config create <config_name.json> -p <base protocol> this will make a config which corresponds to the chosen protocol. You can then edit the option qc_options which takes the method, basis and program. If you use XTB for this stage note that hessians are not available via QCEngine and so it will fail at the hessian stage so you will need to skip it if you plan on using xtb for the full optimisation. You will also need to provide an extra qc specification to the solvent step to overwrite the semi-empirical method if you plan to use DDEC or MBIS to get charges and non-bonded values. You can see the options on the charge base class here.
  2. Yes those settings were found to work well in testing and are hard coded but can be changed by editing the template file found here, is there something that you think we should add to the command to help with calculations?
  3. Yes looking back this is rather an arbitrary limit which I can certainly remove note you will need to make sure you provide enough cores and memory as this is split between the workers. To remove the limit in the dev version I think you just need to remove the le=4 from the field.

@howlfwq
Copy link
Author

howlfwq commented Jun 17, 2022

Is it possible to include ORCA for the QM calculations since I know some QM methods are faster and more accurate but only available in ORCA.
Also, does Qubekit use Openff (ie. use SMIRKS) to identify all the parameters in the parametrisation step by default?

@jthorton
Copy link
Contributor

Not currently we run all of our QM calculations through QCEngine to have only one consistent interface to maintain and the ORCA harness never got finished, I am sure they would welcome your contribution though if you are familiar with the code.

Also, does Qubekit use Openff (ie. use SMIRKS) to identify all the parameters in the parametrisation step by default?

Yes by default we parameterise using OpenFF, some of these parameters are then replaced like the bond, angles and nonbonded terms and we keep some terms like impropers or rigid dihedrals like those in a benzene ring.

@howlfwq
Copy link
Author

howlfwq commented Jun 20, 2022

1. To change the QM method you will need to make a config file either via python or using the CLI, from the CLI you can do `qubekit config create <config_name.json> -p <base protocol>` this will make a config which corresponds to the chosen protocol. You can then edit the option `qc_options` which takes the method, basis and program. If you use XTB for this stage note that hessians are not available via QCEngine and so it will fail at the hessian stage so you will need to skip it if you plan on using xtb for the full optimisation. You will also need to provide an extra qc specification to the solvent step to overwrite the semi-empirical method if you plan to use DDEC or MBIS to get charges and non-bonded values. You can see the options on the charge base class [here](https://github.com/qubekit/QUBEKit/blob/2ba56dc0e4f72141c2295cf7f1e5c3660cbfd72a/qubekit/charges/base.py#L20).

Hi @jthorton , I saw the 15 protocols, which include gaussian and psi4. Is torchani available in Qubekit? I checked QCEngine and it has torchani implemented. But I got error for the hessian part when I use torchani for the qubekit. The following is the content of Qubekit.err.
Traceback (most recent call last):
File "/public/home/user/anaconda3/envs/qubekit/lib/python3.9/site-packages/qubekit/workflow/workflow.py", line 335, in _run_stage
result_mol = stage.run(
File "/public/home/user/anaconda3/envs/qubekit/lib/python3.9/site-packages/qubekit/workflow/helper_stages.py", line 72, in run
molecule.wbo = result.extras["qcvars"]["WIBERG_LOWDIN_INDICES"]
KeyError: 'qcvars'
I also attached the config.json file I used for the qubekit with torchani program
config_ani_1.txt
.

@jthorton
Copy link
Contributor

Thanks for testing this out @howlfwq normally we just use the ani models(1 and 2) as pre-optimisation methods as we strugle with convergence issues. I can fix this issue though which will allow you to use the hessian matrix predicted by ani note that I am not sure how accurate the parameters will be. You will also need to update the config file to use a method and basis in psi4 for the charge calculation part if you plan on going that far in the workflow.

@howlfwq
Copy link
Author

howlfwq commented Jun 29, 2022

Thank you @jthorton! We are about to have an updated ANI version to fix some issues. And I may use that version instead of the ani1&2. Can you fix that issue or maybe give me some hints to fix that? Right now, I found that error releated to the 'qcvar' part, which inclues the WIBERG_LOWDIN_INDICES. This 'WIBERG_LOWDIN_INDICES' calculation is calculated in gaussian but not in ANI.

For the psi4, there are conflicts between psi4 and qubekit. I can't install psi4 properly with qubekit in the same env using conda. Is there a proper way to install them both?(have fixed the installation problem.)

@jthorton
Copy link
Contributor

jthorton commented Jul 6, 2022

Hi @howlfwq this should now be fixed in master by #320.

We are about to have an updated ANI version to fix some issues.

A new version of ANI sounds very exciting!, we have tested using ANI quite a lot for torsiondrives and would be very interested in trying out any new version if you could give us access to the model?

For the psi4, there are conflicts between psi4 and qubekit.

We have found that the best way to avoid conflicts with Psi4 is to include it when creating the environment and that using mamba also helps. The following command should make an environment on linux mamba create -n qubekit_psi4 -c psi4 -c conda-forge -c defaults python=3.8 qubekit psi4 note that you will then need to install the master branch of qubekit to use the fix.

@howlfwq
Copy link
Author

howlfwq commented Jul 8, 2022

Hi @jthorton, I have tested the new version. The hessian part has been fixed, but still get error for the next step (charges). I think it's still related to the qcvar which is required for the mbis charges. The following two are the qubekit error files of ANI with the mbis method, and ANI with the ddec method.
QUBEKit_err.txt
QUBEKiterr.txt

@jthorton
Copy link
Contributor

jthorton commented Jul 8, 2022

Glad the new version works with ANI for the hessian. For the charge stage you will need to use Gaussian or Psi4 unless the new version of ANI can predict MBIS properties (like AIMNET). If not you will need to edit the workflow config file section on charges, there are extra optional fields for the program method and basis which are seperate from the global options and allow a different QC setup for the charge stage. See the attached example where I have edited the config for protocol 0.
ani_protocol_0.txt

@jthorton
Copy link
Contributor

@howlfwq I am going to close this now as I think your original issue is fixed, feel free to reopen this if not or another issue if you have any other problems using ANI.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants