|
| PKMgrYoshimine (std::shared_ptr< PSIO > psio, std::shared_ptr< BasisSet > primary, size_t memory, Options &options) |
| Constructor. More...
|
|
virtual | ~PKMgrYoshimine () |
| Destructor. More...
|
|
virtual void | prestripe_files () |
| Pre-striping the IWL pre-sorted bucket files. More...
|
|
virtual void | prestripe_files_wK () |
| Pre-striping for IWL wK pre-sorted files. More...
|
|
virtual void | form_PK () |
| Gather all steps to form PK. More...
|
|
virtual void | form_PK_wK () |
| Steps to form the supermatrix for wK. More...
|
|
virtual void | allocate_buffers () |
| Allocating the buffers for each thread. More...
|
|
virtual void | allocate_buffers_wK () |
| Allocating buffers for wK integrals. More...
|
|
virtual void | compute_integrals (bool wK=false) |
| Computing the integrals. More...
|
|
virtual void | compute_integrals_wK () |
| computing wK integrals More...
|
|
virtual void | write () |
| Writing of the last partially filled buffers. More...
|
|
virtual void | write_wK () |
| Writing of the last partially filled buffers for wK. More...
|
|
void | sort_ints (bool wK=false) |
| Reading and sorting integrals to generate PK file. More...
|
|
void | sort_ints_wK () |
| Reading and sorting wK integrals for PK file. More...
|
|
void | close_iwl_buckets () |
| Close the IWL bucket files. More...
|
|
void | close_iwl_buckets_wK () |
| Close the IWL bucket file for wK. More...
|
|
void | generate_J_PK (double *twoel_ints, size_t max_size) |
| Generate the J PK supermatrix from IWL integrals. More...
|
|
void | generate_K_PK (double *twoel_ints, size_t max_size) |
| Generate the K PK supermatrix from IWL integrals. More...
|
|
void | generate_wK_PK (double *twoel_ints, size_t max_size) |
| Generate the wK PK supermatrix from IWL integrals. More...
|
|
| PKMgrDisk (std::shared_ptr< PSIO > psio, std::shared_ptr< BasisSet > primary, size_t memory, Options &options) |
| Constructor for PKMgrDisk. More...
|
|
virtual | ~PKMgrDisk () |
| Destructor for PKMgrDisk, does nothing. More...
|
|
void | set_writing (bool tmp) |
| Setter/Getter functions. More...
|
|
bool | writing () const |
|
int | pk_file () const |
|
std::vector< size_t > & | batch_ind_min () |
|
std::vector< size_t > & | batch_ind_max () |
|
std::vector< size_t > & | batch_pq_min () |
|
std::vector< size_t > & | batch_pq_max () |
|
std::vector< int > & | batch_for_pq () |
|
std::shared_ptr< AIOHandler > | AIO () const |
|
std::shared_ptr< PSIO > | psio () const |
|
virtual void | finalize_PK () |
| Finalize the PK file formation. More...
|
|
virtual void | initialize () |
| Initialize sequence for Disk algorithms. More...
|
|
virtual void | initialize_wK () |
|
virtual void | prepare_JK (std::vector< SharedMatrix > D, std::vector< SharedMatrix > Cl, std::vector< SharedMatrix > Cr) |
| Prepare the JK formation for disk algorithms. More...
|
|
void | batch_sizing () |
| Determining the batch sizes. More...
|
|
virtual void | print_batches () |
| Printing out the batches. More...
|
|
void | open_PK_file () |
| Opening the PK file. More...
|
|
virtual void | close_PK_file (bool keep) |
| Closing the files. More...
|
|
virtual void | form_J (std::vector< SharedMatrix > J, std::string exch="", std::vector< SharedMatrix > K=std::vector< SharedMatrix >()) |
| Form J from PK supermatrix, shared_ptr() initialized to null. More...
|
|
virtual void | finalize_JK () |
| Finalize JK matrix formation. More...
|
|
| PKManager (std::shared_ptr< BasisSet > primary, size_t memory, Options &options) |
| Base constructor. More...
|
|
virtual | ~PKManager () |
| Base destructor, does nothing. More...
|
|
bool | do_wk () const |
| Accessor functions for simple data. More...
|
|
double | omega () const |
|
double | cutoff () const |
|
int | nthreads () const |
|
int | nbf () const |
|
std::shared_ptr< ERISieve > | sieve () const |
|
size_t | pk_pairs () const |
|
size_t | pk_size () const |
|
size_t | ntasks () const |
|
size_t | memory () const |
|
SharedPKWrkr | buffer (int i) const |
|
double * | D_glob_vecs (int i) const |
|
double * | JK_glob_vecs (int i) const |
|
std::shared_ptr< BasisSet > | primary () const |
|
bool | is_sym (int i) const |
|
bool | all_sym () const |
|
SharedMatrix | original_D (int N) const |
|
SharedPKWrkr | get_buffer () |
| Accessor that returns buffer corresponding to current thread. More...
|
|
void | set_ntasks (size_t tmp) |
|
virtual void | print_batches_wK () |
| Some printing for wK integrals;. More...
|
|
void | integrals_buffering (const double *buffer, size_t P, size_t Q, size_t R, size_t S) |
| Store the computed integrals in the appropriate buffers. More...
|
|
void | integrals_buffering_wK (const double *buffer, size_t P, size_t Q, size_t R, size_t S) |
| Store the computed wK integrals in the appropriate buffers. More...
|
|
void | form_D_vec (std::vector< SharedMatrix > D, std::vector< SharedMatrix > Cl, std::vector< SharedMatrix > Cr) |
|
void | make_J_vec (std::vector< SharedMatrix > J) |
| Preparing triangular vector for J/K. More...
|
|
void | get_results (std::vector< SharedMatrix > J, std::string exch) |
| Extracting results from vectors to matrix. More...
|
|
void | form_K (std::vector< SharedMatrix > K) |
| Forming K. More...
|
|
virtual void | form_wK (std::vector< SharedMatrix > wK) |
| Forming wK. More...
|
|
void | finalize_D () |
| Finalize and delete the density matrix vectors. More...
|
|
Yoshimine sorting algoritm: the integrals are divided in N batches that can individually fit in memory. Then, all integrals are computed only once, and sorted in N little buffers, one for each batch. As soon as a buffer is full, it gets dumped onto one of N temporary files on disk in IWL format.
Once all integrals are computed and pre-sorted in the N IWL files, each file is read and its integrals sorted, then written onto the PK files.
This routine takes advantage of OMP parallelization, then each thread has N little buffers. All disk writing is handled by a dedicated thread generated by AIOHandler