schrodinger.application.matsci.nano.surfaces_interfaces_mod module¶
Classes and functions to enumerate surfaces and interfaces.
Copyright Schrodinger, LLC. All rights reserved.
- schrodinger.application.matsci.nano.surfaces_interfaces_mod.get_base_names(ref_xtal_asu, ref_base_name_in=None, ads_xtal_asu=None, ads_base_name_in=None)[source]¶
- Return the reference, adsorption, and final combined base names. - Parameters
- ref_xtal_asu (str) – reference xtal input file 
- ref_base_name_in (str or None) – reference base name or None if none has been given 
- ads_xtal_asu (str or None) – adsorption xtal input file or None if none has been given 
- ads_base_name_in (str or None) – adsorption base name or None if none has been given 
 
- Return type
- str, str or None, str 
- Returns
- reference, adsorption, and final combined base names, the adsorption base name will be None if no adsorption xtal asu is provided 
 
- class schrodinger.application.matsci.nano.surfaces_interfaces_mod.ParserWrapper(scriptname, description)[source]¶
- Bases: - object- Manages the argparse module to parse user command line arguments. 
- schrodinger.application.matsci.nano.surfaces_interfaces_mod.get_surface_kwargs(options_file)[source]¶
- Return a dictionary of surface options from the given options file. - Parameters
- options_file (str or None) – contains options for the surface build or None if there are none in which case the defaults are used 
- Return type
- dict 
- Returns
- contains options for the surface build 
 
- schrodinger.application.matsci.nano.surfaces_interfaces_mod.get_interface_kwargs(options_file)[source]¶
- Return a dictionary of interface options from the given options file. - Parameters
- options_file (str or None) – contains options for the interface build or None if there are none in which case the defaults are used 
- Return type
- dict 
- Returns
- contains options for the interface build 
 
- schrodinger.application.matsci.nano.surfaces_interfaces_mod.get_hkl_indices(flattened_hkl_indices=None, h_min=0, h_max=0, k_min=0, k_max=0, l_min=0, l_max=0)[source]¶
- Collect and return all hkl Miller index triples sorted by increasing l then k then h. - Parameters
- flattened_hkl_indices (list or None) – flattened hkl indices, for example 100, 110, etc. as [1, 0, 0, 1, 1, 0, …] 
- h_min (int) – minimum h index 
- h_max (int) – maximum h index 
- k_min (int) – minimum k index 
- k_max (int) – maximum k index 
- l_min (int) – minimum l index 
- l_max (int) – maximum l index 
 
- Raises
- ValueError – if there is an issue 
- Return type
- list 
- Returns
- contains sorted tuples of hkl triples 
 
- schrodinger.application.matsci.nano.surfaces_interfaces_mod.write_to_file(file_name, structs)[source]¶
- Write the structures to file with the feature’s WAM type - Parameters
- file_name (str) – The path to the file 
- structs (list) – List of structures to write to file 
 
 
- class schrodinger.application.matsci.nano.surfaces_interfaces_mod.Surfaces(xtal_asu, surface_kwargs=None, logger=None)[source]¶
- Bases: - object- Manage the enumeration of surfaces. - __init__(xtal_asu, surface_kwargs=None, logger=None)[source]¶
- Create an instance. - Parameters
- xtal_asu ( - schrodinger.structure.Structure) – the crystalline ASU from which to create surfaces
- surface_kwargs (None or dict) – kwargs for the surface build or None if there are none in which case the defaults will be used 
- logger (logging.Logger or None) – output logger or None if there isn’t one 
 
 
 - getHKLIndices()[source]¶
- Collect and return all hkl Miller index triples for this surface enumeration and sort them according to increasing l then k then h. - Return type
- list 
- Returns
- contains sorted tuples of hkl triples 
 
 - getSurface(cell, hkl, logger=None)[source]¶
- Build and return a slab.Surface. - Parameters
- cell ( - schrodinger.structure.Structure) – a cell
- hkl (tuple) – a triple of Miller indices 
- logger (logging.Logger or None) – output logger or None if there isn’t one 
 
- Return type
- Returns
- the surface object 
 
 - getXtalCell()[source]¶
- Build and return the crystal cell from which surfaces will be created. - Return type
- Returns
- the crystal cell 
 
 - getSurfaces()[source]¶
- Build and return the slab.Surface objects for all surfaces. - Return type
- list of slab.Surface 
- Returns
- contains surface objects 
 
 
- class schrodinger.application.matsci.nano.surfaces_interfaces_mod.Interfaces(ref_surfaces, ads_surfaces, interface_kwargs=None, logger=None)[source]¶
- Bases: - object- Manage the enumeration of interfaces. - __init__(ref_surfaces, ads_surfaces, interface_kwargs=None, logger=None)[source]¶
- Create an instance. - Parameters
- ref_surfaces (list of - schrodinger.structure.Structure) – reference surface ASUs from which interfaces will be created
- ads_surfaces (list of - schrodinger.structure.Structure) – adsorption surface ASUs from which interfaces will be created
- interface_kwargs (None or dict) – kwargs for the interface builds or None if there are none in which case the defaults will be used 
- logger (logging.Logger or None) – output logger or None if there isn’t one 
 
 
 - getInterface(ref_surface, ads_surface)[source]¶
- Build and return a interface_mod.Interface. - Parameters
- ref_surface ( - schrodinger.structure.Structure) – reference surface ASU
- ads_surface ( - schrodinger.structure.Structure) – adsorption surface ASU
 
- Return type
- Returns
- the interface object 
 
 - getInterfaces()[source]¶
- Build and return the interface_mod.Interface objects for all interfaces. - Return type
- list of interface_mod.Interface 
- Returns
- contains interface objects 
 
 
- class schrodinger.application.matsci.nano.surfaces_interfaces_mod.SurfacesInterfaces(ref_xtal_asu, ref_surface_kwargs=None, ads_xtal_asu=None, ads_surface_kwargs=None, interface_kwargs=None, logger=None)[source]¶
- Bases: - object- Manage the enumeration of surfaces and interfaces. - __init__(ref_xtal_asu, ref_surface_kwargs=None, ads_xtal_asu=None, ads_surface_kwargs=None, interface_kwargs=None, logger=None)[source]¶
- Create an instance. - Parameters
- ref_xtal_asu ( - schrodinger.structure.Structure) – the crystalline ASU from which to create reference surfaces
- ref_surface_kwargs (None or dict) – kwargs for the reference surface build or None if there are none in which case the defaults will be used 
- ads_xtal_asu (None or - schrodinger.structure.Structure) – the crystalline ASU from which to create adsorption surfaces or None if interfaces are not needed
- ads_surface_kwargs (None or dict) – kwargs for the adsorption surface build or None if there are none in which case the defaults will be used 
- interface_kwargs (None or dict) – kwargs for the interface build or None if there are none in which case the defaults will be used 
- logger (logging.Logger or None) – output logger or None if there isn’t one 
 
 
 - checkInput()[source]¶
- Check input. - Raises
- ValueError – if any input crystal ASU is missing any lattice parameter structure properties