grid3D module

class pyIsoP.grid3D.grid3D(cif_file, spacing=1.0, cutoff=12.8, temperature=77.0, index=None, auto_init=True, coord=None, cell=None, symbols=None)

Bases: object

Calculates the energy grid for the cif file using a cpu or gpu. ! Does not include the electrostatics

GridInterpolator()

Interpolates the energy grid based on scipy’s RegularGridInterpolator with default settings.

Parameters

grid_obj (instance of the grid3D class) – contains all the information regarding the energy grid used in isotherm prediction

Raises

ValueError

Return type

An interpolator function of the type RegularGridInterpolator from scipy.interpolate

detect_local_minima()

Takes an array and detects the troughs using the local maximum filter. Returns a boolean mask of the troughs (i.e. 1 when the pixel’s value is the neighborhood maximum, 0 otherwise) This can be very useful in molecular siting later on.

dgrid_calc_dask(ff_obj)

Description :type grid_obj: PyIsoP grid object :param grid_obj: contains all the information about the grid initialized using PyIsoP

Parameters

ff_obj (PyIsoP force field object) – contains all the information about the force field parameters for energy grid calculation.

Raises

Return type

Lazy evaluated 3D shortes distance grid as a dask array. Call compute on your client to obtain actual values.

grid_calc(potential_name, ff_obj, rmass=None, T=None)

Calculates the energy grid using ‘numba’ , vectorized over the cpu

Parameters
  • grid_obj (instance of the grid object from the grid3D module.) – contains al the details for the energy grid calculation.

  • potential_name (str) – Name of the potential ‘lj’ or ‘ljfh’

  • ff_obj (Instance of the force field object from the forcefields module) – Contains all the mixing rules for a give functional form

Raises

TypeError, NameError

Return type

Returns the 3D energy grid

grid_calc_dask(ff_obj)

Description :type grid_obj: PyIsoP grid object :param grid_obj: contains all the information about the grid initialized using PyIsoP

Parameters

ff_obj (PyIsoP force field object) – contains all the information about the force field parameters for energy grid calculation.

Raises

Return type

Lazy evaluated 3D energy grid as a dask array. Call compute on your client to obtain actual values.