ABACUS develop
Atomic-orbital Based Ab-initio Computation at UStc
Loading...
Searching...
No Matches
restart_exx_csr.h
Go to the documentation of this file.
1#ifndef ABACUS_SOURCE_IO_MODULE_RESTART_RESTART_EXX_CSR_H
2#define ABACUS_SOURCE_IO_MODULE_RESTART_RESTART_EXX_CSR_H
3
7
8#include <RI/global/Tensor.h>
9#include <map>
10
11namespace ModuleIO
12{
13using TC = std::array<int, 3>;
14using TAC = std::pair<int, TC>;
15
17template <typename Tdata>
18void read_Hexxs_csr(const std::string& file_name,
19 const UnitCell& ucell,
20 const int nspin,
21 const int nbasis,
22 std::vector<std::map<int, std::map<TAC, RI::Tensor<Tdata>>>>& Hexxs);
23
25template <typename Tdata>
26void read_Hexxs_cereal(const std::string& file_name,
27 std::vector<std::map<int, std::map<TAC, RI::Tensor<Tdata>>>>& Hexxs);
28
30template <typename Tdata>
31void write_Hexxs_csr(const std::string& file_name,
32 const UnitCell& ucell,
33 const std::vector<std::map<int, std::map<TAC, RI::Tensor<Tdata>>>>& Hexxs);
34
37template <typename Tdata>
38std::map<Abfs::Vector3_Order<int>, std::map<size_t, std::map<size_t, Tdata>>> calculate_RI_Tensor_sparse(
39 const double& sparse_threshold,
40 const std::map<int, std::map<TAC, RI::Tensor<Tdata>>>& Hexxs,
41 const UnitCell& ucell);
42} // namespace ModuleIO
43
44#endif // ABACUS_SOURCE_IO_MODULE_RESTART_RESTART_EXX_CSR_H
Definition rpa_lri_coeff_v1.h:11
Provide the basic information about unitcell.
Definition unitcell.h:16
Internal helpers shared by the R-space sparse text writers. Declared here (instead of duplicated in e...
Definition csr_reader.cpp:8
void write_Hexxs_csr(const std::string &file_name, const UnitCell &ucell, const std::vector< std::map< int, std::map< TAC, RI::Tensor< Tdata > > > > &Hexxs)
write Hexxs in CSR format
Definition restart_exx_csr.cpp:127
void read_Hexxs_cereal(const std::string &file_name, std::vector< std::map< int, std::map< TAC, RI::Tensor< Tdata > > > > &Hexxs)
read Hexxs in cereal format
Definition restart_exx_csr.cpp:78
void read_Hexxs_csr(const std::string &file_name, const UnitCell &ucell, const int nspin, const int nbasis, std::vector< std::map< int, std::map< TAC, RI::Tensor< Tdata > > > > &Hexxs)
read Hexxs in CSR format
Definition restart_exx_csr.cpp:19
std::pair< int, TC > TAC
Definition restart_exx_csr.h:14
std::map< Abfs::Vector3_Order< int >, std::map< size_t, std::map< size_t, Tdata > > > calculate_RI_Tensor_sparse(const double &sparse_threshold, const std::map< int, std::map< TAC, RI::Tensor< Tdata > > > &Hexxs, const UnitCell &ucell)
Definition restart_exx_csr.cpp:93
std::array< int, 3 > TC
Definition restart_exx_csr.h:13