-
Notifications
You must be signed in to change notification settings - Fork 31
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
Adding CIS, CISD and other options for GAS-ACI calculations #355
Open
huangm29
wants to merge
16
commits into
evangelistalab:main
Choose a base branch
from
huangm29:adding_gas_options
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from 14 commits
Commits
Show all changes
16 commits
Select commit
Hold shift + click to select a range
30ed0db
added gasci stuff
huangm29 b3a773a
major implementations
huangm29 edc1f0b
revoke the changings in tdci
huangm29 8487ce9
adding a test cas with gas-cis
huangm29 fb8121f
fixing a bug that generates wrong number of GAS
huangm29 f11c8d5
Merge remote-tracking branch 'upstream/master' into HEAD
huangm29 6ead8b3
adding comments to the code
huangm29 fdee8e4
fixing a bug
huangm29 08ffec9
minor corrections
huangm29 a5d6f19
bug fixing for gasaci-4
huangm29 9f802c4
adding a method which uses a small full gas as an initial guess
huangm29 3781fa4
Merge remote-tracking branch 'origin/master' into HEAD
huangm29 d742c22
modify gasaci-2 to make sure it is no longer bugged
huangm29 105760a
modify tests.yaml to re-enable gasaci-2
huangm29 d14201b
modify gasaci-2 to test GAS_CISD option
huangm29 462225d
Merge branch 'main' of https://github.com/evangelistalab/forte into a…
huangm29 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -78,7 +78,10 @@ void AdaptiveCI::startup() { | |
|
||
gas_iteration_ = false; | ||
if (options_->get_str("ACTIVE_REF_TYPE") == "GAS_SINGLE" or | ||
options_->get_str("ACTIVE_REF_TYPE") == "GAS") { | ||
options_->get_str("ACTIVE_REF_TYPE") == "GAS" or | ||
options_->get_str("ACTIVE_REF_TYPE") == "GAS_CIS" or | ||
options_->get_str("ACTIVE_REF_TYPE") == "GAS_CISD" or | ||
options_->get_str("ACTIVE_REF_TYPE") == "GAS_CID") { | ||
gas_iteration_ = true; | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This connects to the point above. The use of GAS should be triggered by the user passing a GAS space, not by choosing an additional keyword. |
||
} | ||
|
||
|
@@ -569,19 +572,15 @@ void AdaptiveCI::pre_iter_preparation() { | |
gas_single_criterion_ = ref.gas_single_criterion(); | ||
gas_double_criterion_ = ref.gas_double_criterion(); | ||
gas_electrons_ = ref.gas_electrons(); | ||
rel_gas_mos.clear(); | ||
for (size_t gas_count = 0; gas_count < 6; gas_count++) { | ||
std::string space = "GAS" + std::to_string(gas_count + 1); | ||
std::vector<size_t> relative_mo; | ||
auto gas_mo = mo_space_info_->absolute_mo(space); | ||
for (size_t i = 0, imax = gas_mo.size(); i < imax; ++i) { | ||
relative_mo.push_back(re_ab_mo[gas_mo[i]]); | ||
} | ||
if (!relative_mo.empty()) { | ||
gas_num_ = gas_num_ + 1; | ||
} | ||
|
||
relative_gas_mo_.push_back(relative_mo); | ||
auto abs_mos = mo_space_info_->absolute_mo(space); | ||
if (abs_mos.size() == 0) | ||
continue; | ||
rel_gas_mos.push_back(mo_space_info_->pos_in_space(space, "ACTIVE")); | ||
} | ||
gas_num_ = rel_gas_mos.size(); | ||
} | ||
if ((options_->get_bool("SCI_CORE_EX")) and (root_ > 0)) { | ||
|
||
|
@@ -950,7 +949,7 @@ void AdaptiveCI::print_gas_wfn(DeterminantHashVec& space, std::shared_ptr<psi::M | |
std::vector<int> occ_b; | ||
std::vector<int> vir_a; | ||
std::vector<int> vir_b; | ||
for (const auto& p : relative_gas_mo_[gas_count]) { | ||
for (const auto& p : rel_gas_mos[gas_count]) { | ||
if (det.get_alfa_bit(p)) { | ||
occ_a.push_back(p); | ||
} else { | ||
|
This file contains 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
Large diffs are not rendered by default.
Oops, something went wrong.
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we need "GAS_CIS", "GAS_CISD", "GAS_CID" when we already have "CIS", "CID", "CISD"? Can't the user just use these last ones and the code automatically understands if one is using GAS or not? Unless these are supposed to be both valid for GAS (e.g. "CIS" and "GAS_CIS" are both valid and give different results in a GAS computation) then this is potentially a confusing redundancy. Also, I would suggest using "GAS_SINGLE_DET" instead of "GAS_SINGLE".