Skip to content

Commit

Permalink
Commit formatting and linting fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
pre-commit-ci[bot] committed Oct 26, 2023
1 parent ee87b8e commit e48c022
Show file tree
Hide file tree
Showing 9 changed files with 22 additions and 17 deletions.
6 changes: 4 additions & 2 deletions src/laue_dials/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,11 @@

if sys.version_info[:2] >= (3, 8):
# TODO: Import directly (no need for conditional) when `python_requires = >= 3.8`
from importlib.metadata import PackageNotFoundError, version # pragma: no cover
from importlib.metadata import (PackageNotFoundError, # pragma: no cover
version)
else:
from importlib_metadata import PackageNotFoundError, version # pragma: no cover
from importlib_metadata import (PackageNotFoundError, # pragma: no cover
version)

try:
# Change here if project is renamed and does not equal the package name
Expand Down
5 changes: 2 additions & 3 deletions src/laue_dials/algorithms/laue.py
Original file line number Diff line number Diff line change
Expand Up @@ -100,9 +100,8 @@ def gen_beam_models(expts, refls):
# Imports
from copy import deepcopy

from dials.algorithms.refinement.prediction.managed_predictors import (
ExperimentsPredictorFactory,
)
from dials.algorithms.refinement.prediction.managed_predictors import \
ExperimentsPredictorFactory

# Instantiate new ExperimentList/reflection_table
new_expts = ExperimentList()
Expand Down
6 changes: 4 additions & 2 deletions src/laue_dials/command_line/index.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,11 @@

import libtbx.phil
from dials.util import show_mail_handle_errors
from dials.util.options import ArgumentParser, reflections_and_experiments_from_files
from dials.util.options import (ArgumentParser,
reflections_and_experiments_from_files)

from laue_dials.algorithms.monochromatic import initial_index, scan_varying_refine
from laue_dials.algorithms.monochromatic import (initial_index,
scan_varying_refine)

logger = logging.getLogger("laue-dials.command_line.index")

Expand Down
3 changes: 2 additions & 1 deletion src/laue_dials/command_line/integrate.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@
from cctbx import sgtbx
from dials.array_family import flex
from dials.util import show_mail_handle_errors
from dials.util.options import ArgumentParser, reflections_and_experiments_from_files
from dials.util.options import (ArgumentParser,
reflections_and_experiments_from_files)

from laue_dials.algorithms.integration import SegmentedImage

Expand Down
3 changes: 2 additions & 1 deletion src/laue_dials/command_line/optimize_indexing.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,8 @@
import numpy as np
from dials.array_family.flex import reflection_table
from dials.util import show_mail_handle_errors
from dials.util.options import ArgumentParser, reflections_and_experiments_from_files
from dials.util.options import (ArgumentParser,
reflections_and_experiments_from_files)
from dxtbx.model import ExperimentList

logger = logging.getLogger("laue-dials.command_line.optimize_indexing")
Expand Down
3 changes: 2 additions & 1 deletion src/laue_dials/command_line/plot_wavelengths.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@

import libtbx.phil
from dials.util import show_mail_handle_errors
from dials.util.options import ArgumentParser, reflections_and_experiments_from_files
from dials.util.options import (ArgumentParser,
reflections_and_experiments_from_files)
from matplotlib import pyplot as plt

logger = logging.getLogger("laue-dials.command_line.plot_wavelengths")
Expand Down
3 changes: 2 additions & 1 deletion src/laue_dials/command_line/predict.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@
from dials.array_family import flex
from dials.array_family.flex import reflection_table
from dials.util import show_mail_handle_errors
from dials.util.options import ArgumentParser, reflections_and_experiments_from_files
from dials.util.options import (ArgumentParser,
reflections_and_experiments_from_files)
from dxtbx.model import ExperimentList

from laue_dials.algorithms.outliers import gen_kde
Expand Down
7 changes: 2 additions & 5 deletions src/laue_dials/command_line/refine.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,8 @@
from dxtbx.model import ExperimentList
from dxtbx.model.experiment_list import ExperimentListFactory

from laue_dials.algorithms.laue import (
gen_beam_models,
remove_beam_models,
store_wavelengths,
)
from laue_dials.algorithms.laue import (gen_beam_models, remove_beam_models,
store_wavelengths)

logger = logging.getLogger("laue-dials.command_line.refine")

Expand Down
3 changes: 2 additions & 1 deletion src/laue_dials/command_line/sequence_to_stills.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
from dials.array_family import flex
from dials.array_family.flex import reflection_table
from dials.util import show_mail_handle_errors
from dials.util.options import ArgumentParser, reflections_and_experiments_from_files
from dials.util.options import (ArgumentParser,
reflections_and_experiments_from_files)
from dxtbx.model import MosaicCrystalSauter2014
from dxtbx.model.experiment_list import Experiment, ExperimentList
from libtbx.phil import parse
Expand Down

0 comments on commit e48c022

Please sign in to comment.