PyXtal
PyXtal (pronounced pie-crystal
) is an open source Python library for the
ab-initio generation of random crystal structures. It has the following features:
Generation of atomic structures for a given symmetry and stoichiometry (0-3D)
Generation of molecular crystals (1-3D) with the support of special Wyckoff positions
Internal support of
cif
file and many other formats viapymatgen
orASE
Easy access to symmetry information (e.g., Wyckoff, site symmetry and international symbols)
X-ray diffraction analysis and its online application
Structural manipulation via symmetry relation (both subgroup and supergroup)
Geometry optimization from built-in and external optimization methods
The current version is 0.6.5
at GitHub.
It is available for use under the MIT license. Expect updates upon request by
Qiang Zhu's group at the
University of North Carolina at Charlotte.
PyXtal is an open source project. You are welcome to contribute it directly via the GitHub platform or send your comments and suggestions to the developer.
A basic tutorial is provided below for common functions. Additionally, documentation and source code are provided for individual modules.
For an experienced Python user who are familiar with Jupyter notebook, you are also encouraged to check out the following examples
Tutorial
Indices and tables
Modules
- pyxtal package
print_logo()
pyxtal
pyxtal.apply_perturbation()
pyxtal.are_valid_numIons()
pyxtal.build()
pyxtal.check_H_coordination()
pyxtal.check_distance()
pyxtal.check_mapping()
pyxtal.check_short_distances()
pyxtal.check_short_distances_by_dict()
pyxtal.check_validity()
pyxtal.copy()
pyxtal.find_matched_lattice()
pyxtal.from_1d_rep()
pyxtal.from_CSD()
pyxtal.from_json()
pyxtal.from_random()
pyxtal.from_seed()
pyxtal.from_spg_wps_rep()
pyxtal.from_tabular_representation()
pyxtal.get_1D_comp()
pyxtal.get_1D_representation()
pyxtal.get_1d_rep_x()
pyxtal.get_XRD()
pyxtal.get_alternatives()
pyxtal.get_density()
pyxtal.get_dimensionality()
pyxtal.get_disps_optim()
pyxtal.get_disps_sets()
pyxtal.get_disps_single()
pyxtal.get_dof()
pyxtal.get_forcefield()
pyxtal.get_free_axis()
pyxtal.get_init_translations()
pyxtal.get_intermolecular_energy()
pyxtal.get_neighboring_dists()
pyxtal.get_neighboring_molecules()
pyxtal.get_num_torsions()
pyxtal.get_site_labels()
pyxtal.get_spherical_images()
pyxtal.get_std_representation()
pyxtal.get_structure_factor()
pyxtal.get_tabular_representation()
pyxtal.get_transition()
pyxtal.get_transition_by_path()
pyxtal.get_xtal_string()
pyxtal.get_zprime()
pyxtal.has_special_site()
pyxtal.is_duplicate()
pyxtal.load_dict()
pyxtal.make_transitions()
pyxtal.optimize_lattice()
pyxtal.remove_species()
pyxtal.remove_water()
pyxtal.resort()
pyxtal.resort_species()
pyxtal.save_dict()
pyxtal.set_cutoff()
pyxtal.set_site_coordination()
pyxtal.show()
pyxtal.show_mol_cluster()
pyxtal.sort_sites_by_mult()
pyxtal.sort_sites_by_numIons()
pyxtal.subgroup()
pyxtal.subgroup_by_path()
pyxtal.subgroup_once()
pyxtal.substitute()
pyxtal.substitute_linear()
pyxtal.supergroup()
pyxtal.supergroups()
pyxtal.to_ase()
pyxtal.to_atomic_xtal()
pyxtal.to_file()
pyxtal.to_json()
pyxtal.to_molecular_xtal()
pyxtal.to_pymatgen()
pyxtal.to_pyxtal_center()
pyxtal.to_standard_setting()
pyxtal.to_subgroup()
pyxtal.transform()
pyxtal.translate()
pyxtal.update_from_1d_rep()
- Subpackages
- Submodules
- pyxtal.block_crystal module
- pyxtal.crystal module
- pyxtal.descriptor module
- pyxtal.io module
- pyxtal.lattice module
Lattice
Lattice.add_vacuum()
Lattice.apply_transformation()
Lattice.check_mismatch()
Lattice.copy()
Lattice.encode()
Lattice.find_transition_to_orthoslab()
Lattice.from_1d_representation()
Lattice.from_matrix()
Lattice.from_para()
Lattice.generate_matrix()
Lattice.generate_para()
Lattice.generate_point()
Lattice.get_diff()
Lattice.get_dofs()
Lattice.get_lengths()
Lattice.get_matrix()
Lattice.get_para()
Lattice.get_permutation_matrices()
Lattice.get_transformation_matrices()
Lattice.get_worst_angle()
Lattice.is_valid_matrix()
Lattice.mutate()
Lattice.optimize_multi()
Lattice.optimize_once()
Lattice.reset_matrix()
Lattice.scale()
Lattice.search_transformation()
Lattice.search_transformations()
Lattice.set_matrix()
Lattice.set_para()
Lattice.set_volume()
Lattice.standardize()
Lattice.swap_angle()
Lattice.swap_axis()
Lattice.transform()
Lattice.transform_multi()
gaussian()
generate_cellpara()
generate_cellpara_0D()
generate_cellpara_1D()
generate_cellpara_2D()
matrix2para()
para2matrix()
random_shear_matrix()
random_vector()
- pyxtal.molecular_crystal module
- pyxtal.molecule module
Box
Orientation
compare_mol_connectivity()
find_rotor_from_smile()
generate_molecules()
get_inertia_tensor()
has_non_aromatic_ring()
is_compatible_symmetry()
make_graph()
pyxtal_molecule
pyxtal_molecule.align()
pyxtal_molecule.apply_inversion()
pyxtal_molecule.copy()
pyxtal_molecule.get_box()
pyxtal_molecule.get_box_coordinates()
pyxtal_molecule.get_center()
pyxtal_molecule.get_coefs_matrix()
pyxtal_molecule.get_energy()
pyxtal_molecule.get_orientation()
pyxtal_molecule.get_orientations_in_wp()
pyxtal_molecule.get_orientations_in_wps()
pyxtal_molecule.get_principle_axes()
pyxtal_molecule.get_radius()
pyxtal_molecule.get_rmsd()
pyxtal_molecule.get_rmsd2()
pyxtal_molecule.get_symbols()
pyxtal_molecule.get_symmetry()
pyxtal_molecule.get_tols_matrix()
pyxtal_molecule.get_torsion_angles()
pyxtal_molecule.list_molecules()
pyxtal_molecule.load_str()
pyxtal_molecule.perturb_torsion()
pyxtal_molecule.rdkit_mol()
pyxtal_molecule.rdkit_mol_init()
pyxtal_molecule.relax()
pyxtal_molecule.reset_positions()
pyxtal_molecule.save_str()
pyxtal_molecule.set_labels()
pyxtal_molecule.set_torsion_angles()
pyxtal_molecule.show()
pyxtal_molecule.show_box()
pyxtal_molecule.swap_axis()
pyxtal_molecule.to_ase()
random()
reoriented_molecule()
- pyxtal.operations module
OperationAnalyzer
aa2matrix()
angle()
apply_ops()
apply_ops_diagonal()
are_equal()
check_distance()
check_images()
create_matrix()
distance()
distance_matrix()
distance_matrix_no_PBC()
filtered_coords()
filtered_coords_euclidean()
find_ids()
get_best_match()
get_inverse()
get_inverse_ops()
is_orthogonal()
rotate_vector()
verify_distances()
- pyxtal.representation module
- pyxtal.supergroup module
find_mapping()
find_mapping_per_element()
find_xyz()
new_path()
new_structure()
search_G1()
search_G2()
supergroup
supergroup.calc_disps()
supergroup.get_coord_H()
supergroup.get_initial_mask()
supergroup.make_pyxtal_in_supergroup()
supergroup.make_pyxtals_in_subgroup()
supergroup.make_supergroup()
supergroup.print_detail()
supergroup.print_wp()
supergroup.search_supergroup()
supergroup.sort_solutions()
supergroup.symmetrize()
supergroup.symmetrize_dist()
supergroup.symmetrize_site_double_k()
supergroup.symmetrize_site_double_t()
supergroup.symmetrize_site_multi()
supergroup.symmetrize_site_single()
supergroups
write_poscars()
- pyxtal.symmetry module
Group
Group.add_k_transitions()
Group.cellsize()
Group.check_compatible()
Group.clean_lists()
Group.get_alternatives()
Group.get_ferroelectric_groups()
Group.get_free_axis()
Group.get_index_by_letter()
Group.get_lattice_dof()
Group.get_lists()
Group.get_lists_mol()
Group.get_max_k_subgroup()
Group.get_max_subgroup()
Group.get_max_subgroup_numbers()
Group.get_max_t_subgroup()
Group.get_min_supergroup()
Group.get_site_dof()
Group.get_splitters_from_relation()
Group.get_splitters_from_structure()
Group.get_symmetry_directions()
Group.get_valid_solutions()
Group.get_wp_by_letter()
Group.get_wp_list()
Group.get_wyckoff_position()
Group.get_wyckoff_position_from_xyz()
Group.is_valid_combination()
Group.list_groups()
Group.list_wyckoff_combinations()
Group.path_to_general_wp()
Group.path_to_subgroup()
Group.search_subgroup_paths()
Group.search_supergroup_paths()
Group.short_path_to_general_wp()
Hall
Wyckoff_position
Wyckoff_position.apply_ops()
Wyckoff_position.are_equivalent_pts()
Wyckoff_position.copy()
Wyckoff_position.distance_check()
Wyckoff_position.equivalent_set()
Wyckoff_position.from_dict()
Wyckoff_position.from_group_and_index()
Wyckoff_position.from_group_and_letter()
Wyckoff_position.from_index_quick()
Wyckoff_position.from_symops()
Wyckoff_position.from_symops_wo_group()
Wyckoff_position.gen_pos()
Wyckoff_position.get_all_positions()
Wyckoff_position.get_dof()
Wyckoff_position.get_euclidean_generator()
Wyckoff_position.get_euclidean_ops()
Wyckoff_position.get_euclidean_symmetries()
Wyckoff_position.get_free_xyzs()
Wyckoff_position.get_frozen_axis()
Wyckoff_position.get_hm_number()
Wyckoff_position.get_hm_symbol()
Wyckoff_position.get_label()
Wyckoff_position.get_ops_from_transformation()
Wyckoff_position.get_position_from_free_xyzs()
Wyckoff_position.get_site_symm_ops()
Wyckoff_position.get_site_symm_wo_translation()
Wyckoff_position.get_site_symmetry()
Wyckoff_position.get_site_symmetry_object()
Wyckoff_position.has_equivalent_ops()
Wyckoff_position.is_pure_translation()
Wyckoff_position.is_standard_setting()
Wyckoff_position.load_dict()
Wyckoff_position.merge()
Wyckoff_position.print_ops()
Wyckoff_position.process_ops()
Wyckoff_position.project()
Wyckoff_position.save_dict()
Wyckoff_position.search_all_generators()
Wyckoff_position.search_generator()
Wyckoff_position.search_generator_dist()
Wyckoff_position.set_euclidean()
Wyckoff_position.set_generators()
Wyckoff_position.set_ops()
Wyckoff_position.short_distances()
Wyckoff_position.swap_axis()
Wyckoff_position.transform_from_matrices()
Wyckoff_position.transform_from_matrix()
Wyckoff_position.update()
Wyckoff_position.update_hall()
Wyckoff_position.update_index()
abc2matrix()
are_equivalent_ops()
check_symmetry_and_dim()
check_wyckoff_position()
choose_wyckoff()
choose_wyckoff_mol()
find_axis_order()
get_all_polar_space_groups()
get_close_packed_groups()
get_generators()
get_pbc_and_lattice()
get_point_group()
get_symbol_and_number()
get_symmetry_directions()
get_symmetry_from_ops()
get_wyckoff_symmetry()
get_wyckoffs()
identity_ops()
index_from_letter()
jk_from_i()
letter_from_index()
op_transform()
op_translation()
organized_wyckoffs()
para2ferro()
rf()
search_cloest_wp()
site_symm()
site_symmetry
site_symmetry.get_highest_symmetry()
site_symmetry.get_name()
site_symmetry.ref_symmetry()
site_symmetry.set_full_hm_symbols()
site_symmetry.set_short_symbols()
site_symmetry.set_table()
site_symmetry.to_beautiful_matrix_representation()
site_symmetry.to_matrix_representation()
site_symmetry.to_matrix_representation_spg()
site_symmetry.to_one_hot()
site_symmetry.unique_symmetry()
swap_xyz_ops()
swap_xyz_string()
symmetry_element_from_axis()
transform_ops()
trim_ops()
- pyxtal.tolerance module
- pyxtal.viz module
- pyxtal.wyckoff_site module
atom_site
atom_site.check_with_ws2()
atom_site.copy()
atom_site.encode()
atom_site.equivalent_set()
atom_site.get_disp()
atom_site.get_translations()
atom_site.load_dict()
atom_site.perturbate()
atom_site.save_dict()
atom_site.search_position()
atom_site.shift_by_swap()
atom_site.substitute_with_linear()
atom_site.substitute_with_single()
atom_site.swap_axis()
atom_site.to_mol_site()
atom_site.update()
mol_site
mol_site.encode()
mol_site.from_1D_dicts()
mol_site.get_coords_and_species()
mol_site.get_distances()
mol_site.get_dists_WP()
mol_site.get_dists_auto()
mol_site.get_ijk_lists()
mol_site.get_min_dist()
mol_site.get_mol_object()
mol_site.get_neighbors_auto()
mol_site.get_neighbors_wp2()
mol_site.is_valid_orientation()
mol_site.load_dict()
mol_site.perturbate()
mol_site.rotate()
mol_site.save_dict()
mol_site.short_dist()
mol_site.short_dist_with_wp2()
mol_site.show()
mol_site.show_molecule_in_box()
mol_site.to_1D_dicts()
mol_site.to_atom_site()
mol_site.translate()
mol_site.update()
mol_site.update_lattice()
mol_site.update_molecule()
mol_site.update_orientation()
- pyxtal.wyckoff_split module
- pyxtal.XRD module