QMCPACK#

class nexus.qmcpack.GCTA(input, system, flavor)[source]#

Bases: DevBase

This class holds the functionality and data to carry out grand canonical twist averaging in Nexus. Throughout the class, the handling of k-points uses unit (crystal) coordinates, which ranges in [0, 1). Note that QMCPACK interally uses the range (-0.5, 0.5) for k-points.

Methods

append(value)

check_charge_neutrality()

Check the net charge of the twist averaged system

check_kmesh_size()

Make sure that NSCF k-points and QMC twists are commensurate for GCTA

check_kpoint_consistency([tol])

The kpoints expected by the GCTA object and what is found in the self.eig_data.data should be consistent.

check_magnetization_accuracy(scf_magnet)

Check that the net magnetization is close to the reference SCF value

class_error(message[, header, exit, trace, ...])

Report an error relating to a class.

error(message[, header, exit, trace])

Report an error inside a class.

first()

gcta_converter_kmapping([tol])

The k-points defined by the GCTA object and the k-points written by a converter may have different ordering.

int_kpoint_weight(float_value[, atol])

This function checks if the float k-point weight/norm is close to its integer value.

keys()

list(*keys)

open_log(filepath)

prim_kpoints()

Returns the k-points used to build the supercell in unit coordinates

read_eshdf_data(filename)

Read the ESHDF eigenvalues, k-point info and store the data in the GCTA instance as an attribute

save([fpath])

sorted_keys()

sum_charge_twists()

Returns the net charge of a system with multiple twists (not averaged)

sum_spin_twists()

Returns the net spin of a system with multiple twists (not averaged)

traceback_dependency(dependency, cls[, levels])

This function provides limited functionality to go back in dependency by a certain level

unfolded_nelecs()

Returns the number of electrons in the primitive cell

unfolded_nkpoints()

Returns the number of unsymmetrized k-points when a supercell is unfolded back to the primitive cell

warn(msg[, indent])

Warning from inside a Nexus class.

adapted_fermi_level

add

add_optional

check_implementation

check_required

check_types

check_types_optional

class_get

class_has

class_items

class_keys

class_log

class_set

class_set_optional

class_set_single

class_warn

clear

close_log

copy

copy_from

copy_to

data_repr

delete

delete_optional

delete_required

dict

extract

extract_optional

get

get_optional

get_path

get_required

inverse

items

last

list_optional

load

log

move_from

move_from_optional

move_to

move_to_optional

not_implemented

obj

path_exists

pwscf_fermi

pwscf_tot_magnet

random_key

select_random

serial

set

set_gcta_occupations

set_optional

set_path

shallow_copy

spin_adapted_fermi_level

to_dict

to_obj

transfer_from

transfer_to

tree

tuple

values

write

write_gcta_report

check_implementation(gcta_possible, dependency)[source]#
static int_kpoint_weight(float_value, atol=1e-08)[source]#

This function checks if the float k-point weight/norm is close to its integer value. If so, returns the integer value.

read_eshdf_data(filename)[source]#

Read the ESHDF eigenvalues, k-point info and store the data in the GCTA instance as an attribute

unfolded_nelecs()[source]#

Returns the number of electrons in the primitive cell

unfolded_nkpoints()[source]#

Returns the number of unsymmetrized k-points when a supercell is unfolded back to the primitive cell

prim_kpoints()[source]#

Returns the k-points used to build the supercell in unit coordinates

check_kmesh_size()[source]#

Make sure that NSCF k-points and QMC twists are commensurate for GCTA

check_kpoint_consistency(tol=1e-08)[source]#

The kpoints expected by the GCTA object and what is found in the self.eig_data.data should be consistent. The kpoints in self.eig_data.data are expected to be in unit coordinates. (Conversion: dot(kpoints, inv(kaxes))). This function checks if there is 1-to-1 mapping between the GCTA object and the converted data.

gcta_converter_kmapping(tol=1e-08)[source]#

The k-points defined by the GCTA object and the k-points written by a converter may have different ordering. We need to figure out the mapping between these two so that the k-points fold into correct twists.

static traceback_dependency(dependency, cls, levels=1)[source]#

This function provides limited functionality to go back in dependency by a certain level

static pwscf_tot_magnet(filepath)[source]#
static pwscf_fermi(filepath, scf_type)[source]#
adapted_fermi_level()[source]#
spin_adapted_fermi_level(scf_magnet)[source]#
set_gcta_occupations(fermi_level)[source]#
sum_charge_twists()[source]#

Returns the net charge of a system with multiple twists (not averaged)

sum_spin_twists()[source]#

Returns the net spin of a system with multiple twists (not averaged)

check_charge_neutrality()[source]#

Check the net charge of the twist averaged system

check_magnetization_accuracy(scf_magnet)[source]#

Check that the net magnetization is close to the reference SCF value

write_gcta_report(locdir, fermi_level, scf_magnet=None)[source]#
class nexus.qmcpack.Qmcpack(**kwargs)[source]#

Bases: Simulation

Attributes:
working_directory

Methods

acquire_dependents(sim)

append(value)

class_error(message[, header, exit, trace, ...])

Report an error relating to a class.

eliminate()

enter(directory[, changedir, msg])

Have Nexus enter a directory and change its current working directory.

error(message[, header, exit, trace])

Report an error inside a class.

first()

keys()

list(*keys)

log(*texts, **kwargs)

Write output to log file.

open_log(filepath)

save([fpath])

separate_inputs(kwargs[, overlapping_kw, ...])

sorted_keys()

traverse_full_cascade(operation, *args, **kwargs)

warn(msg[, indent])

Warning from inside a Nexus class.

active

add

add_optional

analyze

analyzer_type

app_command

attempt_files

block_dependents

check_dependencies

check_required

check_result

check_sim_status

check_status

check_subcascade

check_types

check_types_optional

class_get

class_has

class_items

class_keys

class_log

class_set

class_set_optional

class_set_single

class_warn

clear

clear_all_sims

close_log

code_name

completed

condense_name

copy

copy_file

copy_from

copy_to

create_directories

data_repr

delete

delete_optional

delete_required

depends

dict

dlog

downstream_simids

errfile_text

execute

extract

extract_optional

fake

fill_produces

fill_products

get

get_dependencies

get_optional

get_output

get_output_files

get_path

get_required

get_result

has_afqmc_input

has_generic_input

idstr

incorporate_result

init_job

init_job_extra

input_type

inverse

items

last

leave

list_optional

load

load_analyzer_image

load_image

mem_usage

move_from

move_from_optional

move_to

move_to_optional

not_implemented

obj

outfile_text

path_exists

post_analyze

post_init

post_submit

pre_check_status

pre_create_directories

pre_init

pre_send_files

pre_write_inputs

progress

propagate_identifier

random_key

read_bandinfo_dat

ready

receive_jastrow

receive_pwscf_orbitals

receive_structure

receive_wavefunction

reconstruct_cascade

reset_indicators

reset_wait_ids

save_analyzer_image

save_attempt

save_image

select_random

send_files

serial

set

set_app_name

set_directories

set_files

set_optional

set_path

shallow_copy

show_input

submit

tlog

to_dict

to_obj

transfer_from

transfer_to

traverse_cascade

tree

tuple

twist_average

undo_depends

update_process_id

values

write

write_dependents

write_end_splash

write_inputs

write_prep

write_splash

input_type#

alias of QmcpackInput

analyzer_type#

alias of QmcpackAnalyzer

generic_identifier = 'qmcpack'#
infile_extension = '.in.xml'#
application = 'qmcpack'#
application_properties = {'mpi', 'omp', 'serial'}#
application_results = {'cuspcorr', 'jastrow', 'wavefunction'}#
allowed_requirements = ['none', 'pwscf_orbitals', 'jastrow', 'wavefunction']#
has_afqmc_input()[source]#
post_init()[source]#
propagate_identifier()[source]#
pre_write_inputs(save_image)[source]#
check_result(result_name, sim)[source]#
get_result(result_name, sim)[source]#
incorporate_result(result_name, result, sim)[source]#
check_sim_status()[source]#
get_output_files()[source]#
post_analyze(analyzer)[source]#
app_command()[source]#
twist_average(twistnums)[source]#
write_prep()[source]#
read_bandinfo_dat()[source]#
fill_produces()[source]#
fill_products()[source]#
receive_structure(struct)[source]#
receive_pwscf_orbitals(orb_file)[source]#
receive_jastrow(jastrow_file)[source]#
receive_wavefunction(wf_file)[source]#
nexus.qmcpack.generate_qmcpack(**kwargs)[source]#
nexus.qmcpack.generate_cusp_correction(**kwargs)[source]#