diff --git a/docs/conf.py b/docs/conf.py index d2551b6d..535bdb6d 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -1,4 +1,5 @@ """Sphinx configuration.""" + project = "MDIO" author = "TGS" copyright = "2023, TGS" diff --git a/noxfile.py b/noxfile.py index aef4fc4b..83a6e2b8 100644 --- a/noxfile.py +++ b/noxfile.py @@ -1,6 +1,5 @@ """Nox sessions.""" - import os import shlex import shutil diff --git a/src/mdio/__init__.py b/src/mdio/__init__.py index 21397ee9..19830066 100644 --- a/src/mdio/__init__.py +++ b/src/mdio/__init__.py @@ -1,6 +1,5 @@ """MDIO library.""" - from importlib import metadata from mdio.api import MDIOReader diff --git a/src/mdio/__main__.py b/src/mdio/__main__.py index 109cbc0d..dad3e779 100644 --- a/src/mdio/__main__.py +++ b/src/mdio/__main__.py @@ -1,6 +1,5 @@ """Command-line interface.""" - from __future__ import annotations import importlib diff --git a/src/mdio/api/__init__.py b/src/mdio/api/__init__.py index 4a1a3cd7..8e21983d 100644 --- a/src/mdio/api/__init__.py +++ b/src/mdio/api/__init__.py @@ -1,6 +1,5 @@ """API Module.""" - from .accessor import MDIOReader from .accessor import MDIOWriter diff --git a/src/mdio/api/io_utils.py b/src/mdio/api/io_utils.py index 1d01a1bf..fb704a3d 100644 --- a/src/mdio/api/io_utils.py +++ b/src/mdio/api/io_utils.py @@ -1,6 +1,5 @@ """Utilities related to API functions and classes.""" - from __future__ import annotations from typing import Any diff --git a/src/mdio/commands/copy.py b/src/mdio/commands/copy.py index 50b2d28d..489898e1 100644 --- a/src/mdio/commands/copy.py +++ b/src/mdio/commands/copy.py @@ -1,6 +1,5 @@ """MDIO Dataset copy command.""" - from __future__ import annotations from click import STRING diff --git a/src/mdio/commands/segy.py b/src/mdio/commands/segy.py index 06c39c9f..5a98bb53 100644 --- a/src/mdio/commands/segy.py +++ b/src/mdio/commands/segy.py @@ -1,6 +1,5 @@ """SEG-Y Import/Export CLI Plugin.""" - from typing import Any from click import BOOL diff --git a/src/mdio/constants.py b/src/mdio/constants.py index bdd01353..d549eebb 100644 --- a/src/mdio/constants.py +++ b/src/mdio/constants.py @@ -1,6 +1,5 @@ """Constant values used across MDIO.""" - import numpy as np diff --git a/src/mdio/converters/__init__.py b/src/mdio/converters/__init__.py index b58c2faf..95c50b70 100644 --- a/src/mdio/converters/__init__.py +++ b/src/mdio/converters/__init__.py @@ -1,6 +1,5 @@ """MDIO Data conversion API.""" - from .mdio import mdio_to_segy from .segy import segy_to_mdio diff --git a/src/mdio/converters/mdio.py b/src/mdio/converters/mdio.py index c5a394c6..9cd83661 100644 --- a/src/mdio/converters/mdio.py +++ b/src/mdio/converters/mdio.py @@ -1,6 +1,5 @@ """Conversion from to MDIO various other formats.""" - from __future__ import annotations import os diff --git a/src/mdio/converters/segy.py b/src/mdio/converters/segy.py index 6f121b49..64ced345 100644 --- a/src/mdio/converters/segy.py +++ b/src/mdio/converters/segy.py @@ -1,6 +1,5 @@ """Conversion from SEG-Y to MDIO.""" - from __future__ import annotations import logging diff --git a/src/mdio/core/__init__.py b/src/mdio/core/__init__.py index a557b655..3d4f61b2 100644 --- a/src/mdio/core/__init__.py +++ b/src/mdio/core/__init__.py @@ -1,6 +1,5 @@ """MDIO core functionalities.""" - from mdio.core.dimension import Dimension from mdio.core.grid import Grid diff --git a/src/mdio/core/dimension.py b/src/mdio/core/dimension.py index 8d6a0b06..0cd16350 100644 --- a/src/mdio/core/dimension.py +++ b/src/mdio/core/dimension.py @@ -1,6 +1,5 @@ """Dimension (grid) abstraction and serializers.""" - from __future__ import annotations import inspect diff --git a/src/mdio/core/exceptions.py b/src/mdio/core/exceptions.py index ed1bd7cc..3d3eeaa5 100644 --- a/src/mdio/core/exceptions.py +++ b/src/mdio/core/exceptions.py @@ -1,6 +1,5 @@ """Core exceptions for MDIO.""" - from mdio.exceptions import MDIOError diff --git a/src/mdio/core/grid.py b/src/mdio/core/grid.py index 33cededd..1c0d4086 100644 --- a/src/mdio/core/grid.py +++ b/src/mdio/core/grid.py @@ -1,6 +1,5 @@ """Grid abstraction with serializers.""" - from __future__ import annotations import inspect diff --git a/src/mdio/core/indexing.py b/src/mdio/core/indexing.py index 2eb292e8..4db965fb 100644 --- a/src/mdio/core/indexing.py +++ b/src/mdio/core/indexing.py @@ -1,6 +1,5 @@ """Indexing logic.""" - import itertools from math import ceil diff --git a/src/mdio/core/serialization.py b/src/mdio/core/serialization.py index f957278f..455b5196 100644 --- a/src/mdio/core/serialization.py +++ b/src/mdio/core/serialization.py @@ -3,7 +3,6 @@ Current support for JSON and YAML. """ - import json from abc import ABC from abc import abstractmethod diff --git a/src/mdio/core/utils_write.py b/src/mdio/core/utils_write.py index 6d8ef361..7e23d093 100644 --- a/src/mdio/core/utils_write.py +++ b/src/mdio/core/utils_write.py @@ -1,6 +1,5 @@ """Convenience utilities for writing to Zarr.""" - from typing import Any import zarr diff --git a/src/mdio/exceptions.py b/src/mdio/exceptions.py index 6f1226cd..23f30069 100644 --- a/src/mdio/exceptions.py +++ b/src/mdio/exceptions.py @@ -1,6 +1,5 @@ """Custom exceptions related to MDIO functionality.""" - from __future__ import annotations diff --git a/src/mdio/segy/_standards_common.py b/src/mdio/segy/_standards_common.py index 53bd461a..74b2fbe0 100644 --- a/src/mdio/segy/_standards_common.py +++ b/src/mdio/segy/_standards_common.py @@ -1,6 +1,5 @@ """Common elements for SEG-Y standards datasets.""" - from enum import IntEnum diff --git a/src/mdio/segy/_standards_rev0.py b/src/mdio/segy/_standards_rev0.py index be5e78a5..e0d3bf26 100644 --- a/src/mdio/segy/_standards_rev0.py +++ b/src/mdio/segy/_standards_rev0.py @@ -1,6 +1,5 @@ """SEG-Y Rev 0 standard and its definitions.""" - from mdio.segy.byte_utils import ByteOrder from mdio.segy.byte_utils import Dtype from mdio.segy.byte_utils import OrderedType diff --git a/src/mdio/segy/_workers.py b/src/mdio/segy/_workers.py index 76a2d261..4b61b5d5 100644 --- a/src/mdio/segy/_workers.py +++ b/src/mdio/segy/_workers.py @@ -1,6 +1,5 @@ """Low level workers for parsing and writing SEG-Y to Zarr.""" - from __future__ import annotations from typing import Any diff --git a/src/mdio/segy/blocked_io.py b/src/mdio/segy/blocked_io.py index 75554e02..bc6d1aab 100644 --- a/src/mdio/segy/blocked_io.py +++ b/src/mdio/segy/blocked_io.py @@ -1,6 +1,5 @@ """Functions for doing blocked I/O from SEG-Y.""" - from __future__ import annotations import multiprocessing as mp diff --git a/src/mdio/segy/byte_utils.py b/src/mdio/segy/byte_utils.py index 3714a5f1..7931f721 100644 --- a/src/mdio/segy/byte_utils.py +++ b/src/mdio/segy/byte_utils.py @@ -1,6 +1,5 @@ """Module for custom struct abstraction utilities.""" - import sys from dataclasses import dataclass from enum import Enum diff --git a/src/mdio/segy/creation.py b/src/mdio/segy/creation.py index d8b9b849..dce20aa9 100644 --- a/src/mdio/segy/creation.py +++ b/src/mdio/segy/creation.py @@ -1,6 +1,5 @@ """SEG-Y creation utilities.""" - from __future__ import annotations import os diff --git a/src/mdio/segy/ebcdic.py b/src/mdio/segy/ebcdic.py index 83b0affd..d34487d8 100644 --- a/src/mdio/segy/ebcdic.py +++ b/src/mdio/segy/ebcdic.py @@ -21,7 +21,6 @@ * Then reverse it and get `ASCII_TO_EBCDIC[33]` that maps back to `0x4F` which is "|". """ - import numpy as np diff --git a/src/mdio/segy/exceptions.py b/src/mdio/segy/exceptions.py index 21be01c3..f9bae340 100644 --- a/src/mdio/segy/exceptions.py +++ b/src/mdio/segy/exceptions.py @@ -1,6 +1,5 @@ """Custom exceptions for SEG-Y.""" - from mdio.exceptions import MDIOError diff --git a/src/mdio/segy/geometry.py b/src/mdio/segy/geometry.py index a18a5a00..fe21919b 100644 --- a/src/mdio/segy/geometry.py +++ b/src/mdio/segy/geometry.py @@ -1,6 +1,5 @@ """SEG-Y geometry handling functions.""" - from __future__ import annotations import logging @@ -78,6 +77,7 @@ class ShotGunGeometryType(Enum): Gun 2 -> 2------------------40 """ + A = auto() B = auto() diff --git a/src/mdio/segy/headers.py b/src/mdio/segy/headers.py index c7da6247..b0e91141 100644 --- a/src/mdio/segy/headers.py +++ b/src/mdio/segy/headers.py @@ -1,6 +1,5 @@ """SEG-Y header abstractions.""" - from collections import abc from dataclasses import dataclass from dataclasses import field diff --git a/src/mdio/segy/headers_text.py b/src/mdio/segy/headers_text.py index 427ad94c..502bd092 100644 --- a/src/mdio/segy/headers_text.py +++ b/src/mdio/segy/headers_text.py @@ -1,6 +1,5 @@ """Text header manipulation utilities.""" - from __future__ import annotations from typing import Sequence diff --git a/src/mdio/segy/helpers_segy.py b/src/mdio/segy/helpers_segy.py index cb4bd5ad..13322c5e 100644 --- a/src/mdio/segy/helpers_segy.py +++ b/src/mdio/segy/helpers_segy.py @@ -1,6 +1,5 @@ """Helper functions for tinkering with SEG-Y related Zarr.""" - from zarr import Group from zarr import open_group from zarr.errors import ContainsGroupError diff --git a/src/mdio/segy/ibm_float.py b/src/mdio/segy/ibm_float.py index 209d31f9..787ac8e2 100644 --- a/src/mdio/segy/ibm_float.py +++ b/src/mdio/segy/ibm_float.py @@ -1,6 +1,5 @@ """Low-level floating point conversion operations.""" - import os import numba as nb diff --git a/src/mdio/segy/parsers.py b/src/mdio/segy/parsers.py index 6ac95e57..5c49d645 100644 --- a/src/mdio/segy/parsers.py +++ b/src/mdio/segy/parsers.py @@ -1,6 +1,5 @@ """Parsers for sections of SEG-Y files.""" - from __future__ import annotations from concurrent.futures import ProcessPoolExecutor diff --git a/src/mdio/segy/utilities.py b/src/mdio/segy/utilities.py index 2636d147..bf14d7c2 100644 --- a/src/mdio/segy/utilities.py +++ b/src/mdio/segy/utilities.py @@ -1,6 +1,5 @@ """More utilities for reading SEG-Ys.""" - from __future__ import annotations from typing import Sequence diff --git a/tests/conftest.py b/tests/conftest.py index 19e9e851..91be127b 100644 --- a/tests/conftest.py +++ b/tests/conftest.py @@ -1,6 +1,5 @@ """Test configuration before everything runs.""" - from os import path from urllib.request import urlretrieve diff --git a/tests/integration/conftest.py b/tests/integration/conftest.py index 1d943cfa..0ef324db 100644 --- a/tests/integration/conftest.py +++ b/tests/integration/conftest.py @@ -1,6 +1,5 @@ """Test configuration before everything runs.""" - from __future__ import annotations import os diff --git a/tests/test_main.py b/tests/test_main.py index 6b3de12c..2011ec5f 100644 --- a/tests/test_main.py +++ b/tests/test_main.py @@ -1,6 +1,5 @@ """Test cases for the __main__ module.""" - from pathlib import Path import pytest diff --git a/tests/unit/conftest.py b/tests/unit/conftest.py index 73fed56b..7d83012c 100644 --- a/tests/unit/conftest.py +++ b/tests/unit/conftest.py @@ -1,6 +1,5 @@ """Extra configurations for unit tests.""" - from __future__ import annotations from datetime import datetime diff --git a/tests/unit/test_dimension.py b/tests/unit/test_dimension.py index 9586c9e1..0264bb89 100644 --- a/tests/unit/test_dimension.py +++ b/tests/unit/test_dimension.py @@ -1,6 +1,5 @@ """Dimension tests.""" - import pytest from mdio.core import Dimension diff --git a/tests/unit/test_segy_grid_overrides.py b/tests/unit/test_segy_grid_overrides.py index 11dc954d..00354ee2 100644 --- a/tests/unit/test_segy_grid_overrides.py +++ b/tests/unit/test_segy_grid_overrides.py @@ -1,6 +1,5 @@ """Check grid overrides.""" - from __future__ import annotations from typing import Any diff --git a/tests/unit/test_serialization.py b/tests/unit/test_serialization.py index 65d8416f..12714c1a 100644 --- a/tests/unit/test_serialization.py +++ b/tests/unit/test_serialization.py @@ -1,6 +1,5 @@ """Check lower-level serialization functions.""" - from inspect import Parameter from inspect import Signature diff --git a/tests/unit/test_text_header.py b/tests/unit/test_text_header.py index 8c151b20..434a63aa 100644 --- a/tests/unit/test_text_header.py +++ b/tests/unit/test_text_header.py @@ -1,6 +1,5 @@ """Tests for lower level text header modules.""" - import random import string from binascii import hexlify