diff --git a/datablock.py b/datablock.py index 3cee71e60..388cea62c 100644 --- a/datablock.py +++ b/datablock.py @@ -8,7 +8,7 @@ import libtbx import dxtbx.imageset -import dxtbx.model.compare +import dxtbx.model from dxtbx.format.FormatMultiImage import FormatMultiImage from dxtbx.format.image import ImageBool, ImageDouble from dxtbx.format.Registry import get_format_class_for_file @@ -930,116 +930,3 @@ def __call__(self, a, b): fixed_rotation_tolerance=self.fixed_rotation_tolerance, setting_rotation_tolerance=self.setting_rotation_tolerance, ) - - -class BeamDiff: - def __init__( - self, - wavelength_tolerance=1e-6, - direction_tolerance=1e-6, - polarization_normal_tolerance=1e-6, - polarization_fraction_tolerance=1e-6, - ): - warnings.warn( - "dxtbx.datablock.BeamDiff is deprecated. " - "Use dxtbx.model.compare.beam_diff instead", - DeprecationWarning, - stacklevel=2, - ) - self.wavelength_tolerance = wavelength_tolerance - self.direction_tolerance = direction_tolerance - self.polarization_normal_tolerance = polarization_normal_tolerance - self.polarization_fraction_tolerance = polarization_fraction_tolerance - - def __call__(self, a, b): - return dxtbx.model.compare.beam_diff( - a, - b, - wavelength_tolerance=self.wavelength_tolerance, - direction_tolerance=self.direction_tolerance, - polarization_normal_tolerance=self.polarization_normal_tolerance, - polarization_fraction_tolerance=self.polarization_fraction_tolerance, - ).split("\n") - - -class DetectorDiff: - def __init__( - self, fast_axis_tolerance=1e-6, slow_axis_tolerance=1e-6, origin_tolerance=1e-6 - ): - warnings.warn( - "dxtbx.datablock.DetectorDiff is deprecated. " - "Use dxtbx.model.compare.detector_diff instead", - DeprecationWarning, - stacklevel=2, - ) - self.fast_axis_tolerance = fast_axis_tolerance - self.slow_axis_tolerance = slow_axis_tolerance - self.origin_tolerance = origin_tolerance - - def __call__(self, a, b): - return dxtbx.model.compare.detector_diff( - a, - b, - fast_axis_tolerance=self.fast_axis_tolerance, - slow_axis_tolerance=self.slow_axis_tolerance, - origin_tolerance=self.origin_tolerance, - ).split("\n") - - -class GoniometerDiff: - def __init__( - self, - rotation_axis_tolerance=1e-6, - fixed_rotation_tolerance=1e-6, - setting_rotation_tolerance=1e-6, - ): - warnings.warn( - "dxtbx.datablock.GoniometerDiff is deprecated. " - "Use dxtbx.model.compare.goniometer_diff instead", - DeprecationWarning, - stacklevel=2, - ) - self.rotation_axis_tolerance = rotation_axis_tolerance - self.fixed_rotation_tolerance = fixed_rotation_tolerance - self.setting_rotation_tolerance = setting_rotation_tolerance - - def __call__(self, a, b): - return dxtbx.model.compare.goniometer_diff( - a, - b, - rotation_axis_tolerance=self.rotation_axis_tolerance, - fixed_rotation_tolerance=self.fixed_rotation_tolerance, - setting_rotation_tolerance=self.setting_rotation_tolerance, - ).split("\n") - - -class ScanDiff: - def __init__(self, scan_tolerance=0.03): - warnings.warn( - "dxtbx.datablock.ScanDiff is deprecated. " - "Use dxtbx.model.compare.scan_diff instead", - DeprecationWarning, - stacklevel=2, - ) - self.scan_tolerance = scan_tolerance - - def __call__(self, a, b): - return dxtbx.model.compare.scan_diff( - a, b, scan_tolerance=self.scan_tolerance - ).split("\n") - - -class SequenceDiff: - def __init__(self, tolerance): - warnings.warn( - "dxtbx.datablock.SequenceDiff is deprecated. " - "Use dxtbx.model.compare.sequence_diff instead", - DeprecationWarning, - stacklevel=2, - ) - self._tolerance = tolerance - - def __call__(self, sequence1, sequence2): - return dxtbx.model.compare.sequence_diff( - sequence1, sequence2, tolerance=self._tolerance - ).split("\n") diff --git a/model/experiment_list.py b/model/experiment_list.py index 0aee83bc9..5cc0aa286 100644 --- a/model/experiment_list.py +++ b/model/experiment_list.py @@ -18,7 +18,6 @@ DataBlockTemplateImporter, DetectorComparison, GoniometerComparison, - SequenceDiff, ) from dxtbx.format.Format import Format from dxtbx.format.FormatMultiImage import FormatMultiImage @@ -59,7 +58,6 @@ "DetectorComparison", "ExperimentListFactory", "GoniometerComparison", - "SequenceDiff", ]