Skip to content

Commit

Permalink
Fix imports.
Browse files Browse the repository at this point in the history
  • Loading branch information
lohedges committed Nov 2, 2023
1 parent 5c198e3 commit 1852d09
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/somd2/runner/_runner.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,13 +22,13 @@
__all__ = ["Runner"]


import sire as _sr
from sire import stream as _stream
from sire.system import System as _System

from ..config import Config as _Config
from ..io import dataframe_to_parquet as _dataframe_to_parquet
from ..io import dict_to_yaml as _dict_to_yaml

# Can't create a self.log variable in this class as it causes errors when passed to a processpool
from somd2 import _logger


Expand Down Expand Up @@ -63,13 +63,13 @@ def __init__(self, system, config):
"""

if not isinstance(system, (str, _sr.system.System)):
if not isinstance(system, (str, _System)):
raise TypeError("'system' must be of type 'str' or 'sire.system.System'")

if isinstance(system, str):
# Try to load the stream file.
try:
self._system = _sr.stream.load(system)
self._system = _stream.load(system)
except:
raise IOError(f"Unable to load system from stream file: '{system}'")
else:
Expand Down

0 comments on commit 1852d09

Please sign in to comment.