dials.algorithms.indexing

exception dials.algorithms.indexing.DialsIndexError[source]

Bases: RuntimeError

exception dials.algorithms.indexing.DialsIndexRefineError[source]

Bases: dials.algorithms.indexing.DialsIndexError

dials.algorithms.indexing.indexer

class dials.algorithms.indexing.indexer.Indexer(reflections, experiments, params)[source]

Bases: object

__init__(reflections, experiments, params)[source]

Initialize self. See help(type(self)) for accurate signature.

export_as_json(experiments, file_name='indexed_experiments.json', compact=False)[source]
export_reflections(reflections, file_name='reflections.pickle')[source]
find_lattices()[source]
find_max_cell()[source]
static from_parameters(reflections, experiments, known_crystal_models=None, params=None)[source]
index()[source]
index_reflections(experiments, reflections)[source]
refine(experiments, reflections)[source]
setup_indexing()[source]
show_experiments(experiments, reflections, d_min=None)[source]
dials.algorithms.indexing.indexer.apply_hkl_offset(indices, offset)[source]

dials.algorithms.indexing.stills_indexer

class dials.algorithms.indexing.stills_indexer.StillsIndexer(reflections, experiments, params=None)[source]

Bases: dials.algorithms.indexing.indexer.Indexer

Class for indexing stills

__init__(reflections, experiments, params=None)[source]

Initialize self. See help(type(self)) for accurate signature.

choose_best_orientation_matrix(candidate_orientation_matrices)[source]
experiment_list_for_crystal(crystal)[source]
identify_outliers(params, experiments, indexed)[source]
index()[source]
refine(experiments, reflections)[source]
class dials.algorithms.indexing.stills_indexer.StillsIndexerBasisVectorSearch(reflections, experiments, params=None)[source]

Bases: dials.algorithms.indexing.stills_indexer.StillsIndexer, dials.algorithms.indexing.lattice_search.BasisVectorSearch

class dials.algorithms.indexing.stills_indexer.StillsIndexerKnownOrientation(reflections, experiments, params, known_orientations)[source]

Bases: dials.algorithms.indexing.known_orientation.IndexerKnownOrientation, dials.algorithms.indexing.stills_indexer.StillsIndexer

class dials.algorithms.indexing.stills_indexer.StillsIndexerLatticeSearch(reflections, experiments, params=None)[source]

Bases: dials.algorithms.indexing.stills_indexer.StillsIndexer, dials.algorithms.indexing.lattice_search.LatticeSearch

dials.algorithms.indexing.stills_indexer.calc_2D_rmsd_and_displacements(reflections)[source]
dials.algorithms.indexing.stills_indexer.e_refine(params, experiments, reflections, graph_verbose=False)[source]
dials.algorithms.indexing.stills_indexer.plot_displacements(reflections, predictions, experiments)[source]

dials.algorithms.indexing.model_evaluation

class dials.algorithms.indexing.model_evaluation.ModelEvaluation(refinement_params)[source]

Bases: dials.algorithms.indexing.model_evaluation.Strategy

__init__(refinement_params)[source]

Initialize self. See help(type(self)) for accurate signature.

evaluate(experiments, reflections)[source]
class dials.algorithms.indexing.model_evaluation.ModelRank[source]

Bases: object

__init__()[source]

Initialize self. See help(type(self)) for accurate signature.

append(item)[source]
best_model()[source]
extend(items)[source]
class dials.algorithms.indexing.model_evaluation.ModelRankFilter(check_doubled_cell=True, likelihood_cutoff=0.8, volume_cutoff=1.25, n_indexed_cutoff=0.9)[source]

Bases: dials.algorithms.indexing.model_evaluation.ModelRank

__init__(check_doubled_cell=True, likelihood_cutoff=0.8, volume_cutoff=1.25, n_indexed_cutoff=0.9)[source]

Initialize self. See help(type(self)) for accurate signature.

append(item)[source]
best_model()[source]
extend(items)[source]
filter_by_likelihood(solutions)[source]
filter_by_n_indexed(solutions, n_indexed_cutoff=None)[source]
filter_by_volume(solutions)[source]
update_analysis()[source]
class dials.algorithms.indexing.model_evaluation.ModelRankWeighted(power=2, volume_weight=1, n_indexed_weight=1, rmsd_weight=1)[source]

Bases: dials.algorithms.indexing.model_evaluation.ModelRank

__init__(power=2, volume_weight=1, n_indexed_weight=1, rmsd_weight=1)[source]

Initialize self. See help(type(self)) for accurate signature.

best_model()[source]
combined_scores()[source]
score_by_fraction_indexed(reverse=False)[source]
score_by_rmsd_xy(reverse=False)[source]
score_by_volume(reverse=False)[source]
class dials.algorithms.indexing.model_evaluation.Result(model_likelihood, crystal, rmsds, n_indexed, fraction_indexed, hkl_offset)

Bases: tuple

crystal

Alias for field number 1

fraction_indexed

Alias for field number 4

hkl_offset

Alias for field number 5

model_likelihood

Alias for field number 0

n_indexed

Alias for field number 3

rmsds

Alias for field number 2

class dials.algorithms.indexing.model_evaluation.Strategy[source]

Bases: object

evaluate(experiments, reflections)[source]
dials.algorithms.indexing.model_evaluation.filter_doubled_cell(solutions)[source]

dials.algorithms.indexing.max_cell

dials.algorithms.indexing.max_cell.find_max_cell(reflections, max_cell_multiplier=1.3, step_size=45, nearest_neighbor_percentile=None, histogram_binning='linear', nn_per_bin=5, max_height_fraction=0.25, filter_ice=True, filter_overlaps=True, overlaps_border=0)[source]
class dials.algorithms.indexing.nearest_neighbor.NeighborAnalysis(reflections, step_size=45, tolerance=1.5, max_height_fraction=0.25, percentile=None, histogram_binning='linear', nn_per_bin=5)[source]

Bases: object

__init__(reflections, step_size=45, tolerance=1.5, max_height_fraction=0.25, percentile=None, histogram_binning='linear', nn_per_bin=5)[source]

Initialize self. See help(type(self)) for accurate signature.

plot_histogram(filename='nn_hist.png', figsize=(12, 8))[source]
class dials.algorithms.indexing.assign_indices.AssignIndicesGlobal(tolerance=0.3)[source]

Bases: dials.algorithms.indexing.assign_indices.AssignIndicesStrategy

__init__(tolerance=0.3)[source]

Initialize self. See help(type(self)) for accurate signature.

class dials.algorithms.indexing.assign_indices.AssignIndicesLocal(d_min=None, epsilon=0.05, delta=8, l_min=0.8, nearest_neighbours=20)[source]

Bases: dials.algorithms.indexing.assign_indices.AssignIndicesStrategy

__init__(d_min=None, epsilon=0.05, delta=8, l_min=0.8, nearest_neighbours=20)[source]

Initialize self. See help(type(self)) for accurate signature.

class dials.algorithms.indexing.assign_indices.AssignIndicesStrategy(d_min=None)[source]

Bases: object

__init__(d_min=None)[source]

Initialize self. See help(type(self)) for accurate signature.

dials.algorithms.indexing.compare_orientation_matrices.difference_rotation_matrix_axis_angle(crystal_a, crystal_b, target_angle=0)[source]
dials.algorithms.indexing.compare_orientation_matrices.rotation_matrix_differences(crystal_models, miller_indices=None, comparison='pairwise')[source]
class dials.algorithms.indexing.symmetry.SymmetryHandler(unit_cell=None, space_group=None, max_delta=5)[source]

Bases: object

__init__(unit_cell=None, space_group=None, max_delta=5)[source]

Initialize self. See help(type(self)) for accurate signature.

apply_symmetry(crystal_model)[source]

Apply symmetry constraints to a crystal model.

Returns the crystal model (with symmetry constraints applied) in the same setting as provided as input. The cb_op returned by the method is that necessary to transform that model to the user-provided target symmetry.

Parameters

crystal_model (dxtbx.model.Crystal) – The input crystal model to which to apply symmetry constraints.

Returns: (dxtbx.model.Crystal, cctbx.sgtbx.change_of_basis_op): The crystal model with symmetry constraints applied, and the change_of_basis_op that transforms the returned model to the user-specified target symmetry.

dials.algorithms.indexing.symmetry.find_matching_symmetry(unit_cell, target_space_group, max_delta=5, best_monoclinic_beta=True)[source]
dials.algorithms.indexing.symmetry.metric_supergroup(group)[source]
dials.algorithms.indexing.refinement.refine(params, reflections, experiments)[source]