diff --git a/.gitignore b/.gitignore index 0f61f90..7def23b 100644 --- a/.gitignore +++ b/.gitignore @@ -9,3 +9,4 @@ /src/*.egg-info/ __pycache__/ src/pysol/_version.py +tests/test_new_dipole.py diff --git a/noxfile.py b/noxfile.py index a160001..02de745 100644 --- a/noxfile.py +++ b/noxfile.py @@ -21,7 +21,7 @@ package = "pysol" -python_versions = ["3.10", "3.9", "3.8", "3.7"] +python_versions = ["3.10", "3.9", "3.8"] nox.needs_version = ">= 2021.6.6" nox.options.sessions = ( "pre-commit", diff --git a/poetry.lock b/poetry.lock index f69e1e2..426059f 100644 --- a/poetry.lock +++ b/poetry.lock @@ -1,84 +1,13 @@ [[package]] -name = "anyio" -version = "3.7.0" -description = "High level compatibility layer for multiple asynchronous event loop implementations" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -exceptiongroup = {version = "*", markers = "python_version < \"3.11\""} -idna = ">=2.8" -sniffio = ">=1.1" - -[package.extras] -doc = ["packaging", "Sphinx (>=6.1.0)", "sphinx-rtd-theme", "sphinxcontrib-jquery", "sphinx-autodoc-typehints (>=1.2.0)"] -test = ["anyio", "coverage[toml] (>=4.5)", "hypothesis (>=4.0)", "psutil (>=5.9)", "pytest (>=7.0)", "pytest-mock (>=3.6.1)", "trustme", "uvloop (>=0.17)", "mock (>=4)"] -trio = ["trio (<0.22)"] - -[[package]] -name = "appnope" -version = "0.1.3" -description = "Disable App Nap on macOS >= 10.9" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "argon2-cffi" -version = "21.3.0" -description = "The secure Argon2 password hashing algorithm." -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -argon2-cffi-bindings = "*" - -[package.extras] -dev = ["pre-commit", "cogapp", "tomli", "coverage[toml] (>=5.0.2)", "hypothesis", "pytest", "sphinx", "sphinx-notfound-page", "furo"] -docs = ["sphinx", "sphinx-notfound-page", "furo"] -tests = ["coverage[toml] (>=5.0.2)", "hypothesis", "pytest"] - -[[package]] -name = "argon2-cffi-bindings" -version = "21.2.0" -description = "Low-level CFFI bindings for Argon2" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -cffi = ">=1.0.1" - -[package.extras] -dev = ["pytest", "cogapp", "pre-commit", "wheel"] -tests = ["pytest"] - -[[package]] -name = "arrow" -version = "1.2.3" -description = "Better dates & times for Python" +name = "argcomplete" +version = "3.1.1" +description = "Bash tab completion for argparse" category = "dev" optional = false python-versions = ">=3.6" -[package.dependencies] -python-dateutil = ">=2.7.0" - -[[package]] -name = "asttokens" -version = "2.2.1" -description = "Annotate AST trees with source code positions" -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -six = "*" - [package.extras] -test = ["astroid", "pytest"] +test = ["coverage", "pexpect", "wheel", "ruff", "mypy"] [[package]] name = "attrs" @@ -95,44 +24,6 @@ docs = ["furo", "myst-parser", "sphinx", "sphinx-notfound-page", "sphinxcontrib- tests = ["attrs", "zope-interface"] tests-no-zope = ["cloudpickle", "hypothesis", "mypy (>=1.1.1)", "pympler", "pytest-mypy-plugins", "pytest-xdist", "pytest (>=4.3.0)"] -[[package]] -name = "backcall" -version = "0.2.0" -description = "Specifications for callback functions passed in to an API" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "beautifulsoup4" -version = "4.12.2" -description = "Screen-scraping library" -category = "dev" -optional = false -python-versions = ">=3.6.0" - -[package.dependencies] -soupsieve = ">1.2" - -[package.extras] -html5lib = ["html5lib"] -lxml = ["lxml"] - -[[package]] -name = "bleach" -version = "6.0.0" -description = "An easy safelist-based HTML-sanitizing tool." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -six = ">=1.9.0" -webencodings = "*" - -[package.extras] -css = ["tinycss2 (>=1.1.0,<1.2)"] - [[package]] name = "build" version = "0.10.0" @@ -209,47 +100,38 @@ python-versions = ">=3.7,<4.0" crashtest = ">=0.4.1,<0.5.0" rapidfuzz = ">=2.2.0,<3.0.0" +[[package]] +name = "click" +version = "8.1.3" +description = "Composable command line interface toolkit" +category = "main" +optional = false +python-versions = ">=3.7" + +[package.dependencies] +colorama = {version = "*", markers = "platform_system == \"Windows\""} + [[package]] name = "colorama" version = "0.4.6" description = "Cross-platform colored terminal text." -category = "dev" +category = "main" optional = false python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*,>=2.7" [[package]] -name = "comm" -version = "0.1.3" -description = "Jupyter Python Comm implementation, for usage in ipykernel, xeus-python etc." +name = "colorlog" +version = "6.7.0" +description = "Add colours to the output of Python's logging module." category = "dev" optional = false python-versions = ">=3.6" [package.dependencies] -traitlets = ">=5.3" - -[package.extras] -lint = ["black (>=22.6.0)", "mdformat-gfm (>=0.3.5)", "mdformat (>0.7)", "ruff (>=0.0.156)"] -test = ["pytest"] -typing = ["mypy (>=0.990)"] - -[[package]] -name = "contourpy" -version = "1.0.7" -description = "Python library for calculating contours of 2D quadrilateral grids" -category = "dev" -optional = false -python-versions = ">=3.8" - -[package.dependencies] -numpy = ">=1.16" +colorama = {version = "*", markers = "sys_platform == \"win32\""} [package.extras] -bokeh = ["bokeh", "chromedriver", "selenium"] -docs = ["furo", "sphinx-copybutton"] -mypy = ["contourpy", "docutils-stubs", "mypy (==0.991)", "types-pillow"] -test = ["matplotlib", "pillow", "pytest"] -test-no-images = ["pytest"] +development = ["black", "flake8", "mypy", "pytest", "types-colorama"] [[package]] name = "crashtest" @@ -280,38 +162,6 @@ ssh = ["bcrypt (>=3.1.5)"] test = ["pytest (>=6.2.0)", "pytest-benchmark", "pytest-cov", "pytest-xdist", "pretend"] test-randomorder = ["pytest-randomly"] -[[package]] -name = "cycler" -version = "0.11.0" -description = "Composable style cycles" -category = "dev" -optional = false -python-versions = ">=3.6" - -[[package]] -name = "debugpy" -version = "1.6.7" -description = "An implementation of the Debug Adapter Protocol for Python" -category = "dev" -optional = false -python-versions = ">=3.7" - -[[package]] -name = "decorator" -version = "5.1.1" -description = "Decorators for Humans" -category = "dev" -optional = false -python-versions = ">=3.5" - -[[package]] -name = "defusedxml" -version = "0.7.1" -description = "XML bomb protection for Python stdlib modules" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - [[package]] name = "distlib" version = "0.3.6" @@ -338,87 +188,27 @@ paramiko = ["paramiko"] pgp = ["gpg"] [[package]] -name = "exceptiongroup" -version = "1.1.1" -description = "Backport of PEP 654 (exception groups)" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -test = ["pytest (>=6)"] - -[[package]] -name = "executing" -version = "1.2.0" -description = "Get the currently executing AST node of a frame, and other information" +name = "dunamai" +version = "1.17.0" +description = "Dynamic version generation" category = "dev" optional = false -python-versions = "*" - -[package.extras] -tests = ["asttokens", "pytest", "littleutils", "rich"] - -[[package]] -name = "fastjsonschema" -version = "2.17.1" -description = "Fastest Python implementation of JSON schema" -category = "dev" -optional = false -python-versions = "*" +python-versions = ">=3.5,<4.0" -[package.extras] -devel = ["colorama", "jsonschema", "json-spec", "pylint", "pytest", "pytest-benchmark", "pytest-cache", "validictory"] +[package.dependencies] +packaging = ">=20.9" [[package]] name = "filelock" -version = "3.12.0" +version = "3.12.2" description = "A platform independent file lock." category = "dev" optional = false python-versions = ">=3.7" [package.extras] -docs = ["furo (>=2023.3.27)", "sphinx-autodoc-typehints (>=1.23,!=1.23.4)", "sphinx (>=6.1.3)"] -testing = ["covdefaults (>=2.3)", "coverage (>=7.2.3)", "diff-cover (>=7.5)", "pytest-cov (>=4)", "pytest-mock (>=3.10)", "pytest-timeout (>=2.1)", "pytest (>=7.3.1)"] - -[[package]] -name = "fonttools" -version = "4.39.4" -description = "Tools to manipulate font files" -category = "dev" -optional = false -python-versions = ">=3.8" - -[package.extras] -all = ["fs (>=2.2.0,<3)", "lxml (>=4.0,<5)", "zopfli (>=0.1.4)", "lz4 (>=1.7.4.2)", "matplotlib", "sympy", "skia-pathops (>=0.5.0)", "uharfbuzz (>=0.23.0)", "brotlicffi (>=0.8.0)", "scipy", "brotli (>=1.0.1)", "munkres", "unicodedata2 (>=15.0.0)", "xattr"] -graphite = ["lz4 (>=1.7.4.2)"] -interpolatable = ["scipy", "munkres"] -lxml = ["lxml (>=4.0,<5)"] -pathops = ["skia-pathops (>=0.5.0)"] -plot = ["matplotlib"] -repacker = ["uharfbuzz (>=0.23.0)"] -symfont = ["sympy"] -type1 = ["xattr"] -ufo = ["fs (>=2.2.0,<3)"] -unicode = ["unicodedata2 (>=15.0.0)"] -woff = ["zopfli (>=0.1.4)", "brotlicffi (>=0.8.0)", "brotli (>=1.0.1)"] - -[[package]] -name = "fqdn" -version = "1.5.1" -description = "Validates fully-qualified domain names against RFC 1123, so that they are acceptable to modern bowsers" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0, !=3.1, !=3.2, !=3.3, !=3.4, <4" - -[[package]] -name = "hdfs3" -version = "0.3.1" -description = "Python wrappers for libhdfs3, a native HDFS client" -category = "dev" -optional = false -python-versions = "*" +docs = ["furo (>=2023.5.20)", "sphinx-autodoc-typehints (>=1.23,!=1.23.4)", "sphinx (>=7.0.1)"] +testing = ["covdefaults (>=2.3)", "coverage (>=7.2.7)", "diff-cover (>=7.5)", "pytest-cov (>=4.1)", "pytest-mock (>=3.10)", "pytest-timeout (>=2.1)", "pytest (>=7.3.1)"] [[package]] name = "html5lib" @@ -448,7 +238,7 @@ python-versions = ">=3.5" [[package]] name = "importlib-metadata" -version = "6.6.0" +version = "6.7.0" description = "Read metadata from Python packages" category = "main" optional = false @@ -460,7 +250,7 @@ zipp = ">=0.5" [package.extras] docs = ["sphinx (>=3.5)", "jaraco.packaging (>=9)", "rst.linker (>=1.9)", "furo", "sphinx-lint", "jaraco.tidelift (>=1.4)"] perf = ["ipython"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "flake8 (<5)", "pytest-cov", "pytest-enabler (>=1.3)", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "pytest-flake8", "importlib-resources (>=1.3)"] +testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-ruff", "packaging", "pyfakefs", "flufl.flake8", "pytest-perf (>=0.9.2)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "importlib-resources (>=1.3)"] [[package]] name = "importlib-resources" @@ -485,91 +275,6 @@ category = "dev" optional = false python-versions = ">=3.7" -[[package]] -name = "ipykernel" -version = "6.23.1" -description = "IPython Kernel for Jupyter" -category = "dev" -optional = false -python-versions = ">=3.8" - -[package.dependencies] -appnope = {version = "*", markers = "platform_system == \"Darwin\""} -comm = ">=0.1.1" -debugpy = ">=1.6.5" -ipython = ">=7.23.1" -jupyter-client = ">=6.1.12" -jupyter-core = ">=4.12,<5.0.0 || >=5.1.0" -matplotlib-inline = ">=0.1" -nest-asyncio = "*" -packaging = "*" -psutil = "*" -pyzmq = ">=20" -tornado = ">=6.1" -traitlets = ">=5.4.0" - -[package.extras] -cov = ["coverage", "curio", "matplotlib", "pytest-cov", "trio"] -docs = ["myst-parser", "pydata-sphinx-theme", "sphinx", "sphinx-autodoc-typehints", "sphinxcontrib-github-alt", "sphinxcontrib-spelling", "trio"] -pyqt5 = ["pyqt5"] -pyside6 = ["pyside6"] -test = ["flaky", "ipyparallel", "pre-commit", "pytest-asyncio", "pytest-cov", "pytest-timeout", "pytest (>=7.0)"] - -[[package]] -name = "ipython" -version = "8.13.0" -description = "IPython: Productive Interactive Computing" -category = "dev" -optional = false -python-versions = ">=3.8" - -[package.dependencies] -appnope = {version = "*", markers = "sys_platform == \"darwin\""} -backcall = "*" -colorama = {version = "*", markers = "sys_platform == \"win32\""} -decorator = "*" -jedi = ">=0.16" -matplotlib-inline = "*" -pexpect = {version = ">4.3", markers = "sys_platform != \"win32\""} -pickleshare = "*" -prompt-toolkit = ">=3.0.30,<3.0.37 || >3.0.37,<3.1.0" -pygments = ">=2.4.0" -stack-data = "*" -traitlets = ">=5" -typing-extensions = {version = "*", markers = "python_version < \"3.10\""} - -[package.extras] -all = ["black", "ipykernel", "setuptools (>=18.5)", "sphinx (>=1.3)", "sphinx-rtd-theme", "docrepr", "matplotlib", "stack-data", "pytest (<7)", "typing-extensions", "pytest (<7.1)", "pytest-asyncio", "testpath", "nbconvert", "nbformat", "ipywidgets", "notebook", "ipyparallel", "qtconsole", "curio", "matplotlib (!=3.2.0)", "numpy (>=1.21)", "pandas", "trio"] -black = ["black"] -doc = ["ipykernel", "setuptools (>=18.5)", "sphinx (>=1.3)", "sphinx-rtd-theme", "docrepr", "matplotlib", "stack-data", "pytest (<7)", "typing-extensions", "pytest (<7.1)", "pytest-asyncio", "testpath"] -kernel = ["ipykernel"] -nbconvert = ["nbconvert"] -nbformat = ["nbformat"] -notebook = ["ipywidgets", "notebook"] -parallel = ["ipyparallel"] -qtconsole = ["qtconsole"] -test = ["pytest (<7.1)", "pytest-asyncio", "testpath"] -test_extra = ["pytest (<7.1)", "pytest-asyncio", "testpath", "curio", "matplotlib (!=3.2.0)", "nbformat", "numpy (>=1.21)", "pandas", "trio"] - -[[package]] -name = "ipython-genutils" -version = "0.2.0" -description = "Vestigial utilities from IPython" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "isoduration" -version = "20.11.0" -description = "Operations with ISO 8601 durations" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -arrow = ">=0.15.0" - [[package]] name = "jaraco.classes" version = "3.2.3" @@ -585,22 +290,6 @@ more-itertools = "*" docs = ["sphinx (>=3.5)", "jaraco.packaging (>=9)", "rst.linker (>=1.9)", "jaraco.tidelift (>=1.4)"] testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "pytest-flake8", "flake8 (<5)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)"] -[[package]] -name = "jedi" -version = "0.18.2" -description = "An autocompletion tool for Python that can be used for text editors." -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -parso = ">=0.8.0,<0.9.0" - -[package.extras] -docs = ["Jinja2 (==2.11.3)", "MarkupSafe (==1.1.1)", "Pygments (==2.8.1)", "alabaster (==0.7.12)", "babel (==2.9.1)", "chardet (==4.0.0)", "commonmark (==0.8.1)", "docutils (==0.17.1)", "future (==0.18.2)", "idna (==2.10)", "imagesize (==1.2.0)", "mock (==1.0.1)", "packaging (==20.9)", "pyparsing (==2.4.7)", "pytz (==2021.1)", "readthedocs-sphinx-ext (==2.1.4)", "recommonmark (==0.5.0)", "requests (==2.25.1)", "six (==1.15.0)", "snowballstemmer (==2.1.0)", "sphinx-rtd-theme (==0.4.3)", "sphinx (==1.8.5)", "sphinxcontrib-serializinghtml (==1.1.4)", "sphinxcontrib-websupport (==1.2.4)", "urllib3 (==1.26.4)"] -qa = ["flake8 (==3.8.3)", "mypy (==0.782)"] -testing = ["Django (<3.1)", "attrs", "colorama", "docopt", "pytest (<7.0.0)"] - [[package]] name = "jeepney" version = "0.8.0" @@ -613,28 +302,6 @@ python-versions = ">=3.7" test = ["pytest", "pytest-trio", "pytest-asyncio (>=0.17)", "testpath", "trio", "async-timeout"] trio = ["trio", "async-generator"] -[[package]] -name = "jinja2" -version = "3.1.2" -description = "A very fast and expressive template engine." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -MarkupSafe = ">=2.0" - -[package.extras] -i18n = ["Babel (>=2.7)"] - -[[package]] -name = "jsonpointer" -version = "2.3" -description = "Identify specific nodes in a JSON document (RFC 6901)" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - [[package]] name = "jsonschema" version = "4.17.3" @@ -645,447 +312,117 @@ python-versions = ">=3.7" [package.dependencies] attrs = ">=17.4.0" -fqdn = {version = "*", optional = true, markers = "extra == \"format-nongpl\""} -idna = {version = "*", optional = true, markers = "extra == \"format-nongpl\""} importlib-resources = {version = ">=1.4.0", markers = "python_version < \"3.9\""} -isoduration = {version = "*", optional = true, markers = "extra == \"format-nongpl\""} -jsonpointer = {version = ">1.13", optional = true, markers = "extra == \"format-nongpl\""} pkgutil-resolve-name = {version = ">=1.3.10", markers = "python_version < \"3.9\""} pyrsistent = ">=0.14.0,<0.17.0 || >0.17.0,<0.17.1 || >0.17.1,<0.17.2 || >0.17.2" -rfc3339-validator = {version = "*", optional = true, markers = "extra == \"format-nongpl\""} -rfc3986-validator = {version = ">0.1.0", optional = true, markers = "extra == \"format-nongpl\""} -uri-template = {version = "*", optional = true, markers = "extra == \"format-nongpl\""} -webcolors = {version = ">=1.11", optional = true, markers = "extra == \"format-nongpl\""} [package.extras] format = ["fqdn", "idna", "isoduration", "jsonpointer (>1.13)", "rfc3339-validator", "rfc3987", "uri-template", "webcolors (>=1.11)"] format-nongpl = ["fqdn", "idna", "isoduration", "jsonpointer (>1.13)", "rfc3339-validator", "rfc3986-validator (>0.1.0)", "uri-template", "webcolors (>=1.11)"] [[package]] -name = "jupyter-client" -version = "8.2.0" -description = "Jupyter protocol implementation and client libraries" +name = "keyring" +version = "23.13.1" +description = "Store and access your passwords safely." category = "dev" optional = false -python-versions = ">=3.8" +python-versions = ">=3.7" [package.dependencies] -importlib-metadata = {version = ">=4.8.3", markers = "python_version < \"3.10\""} -jupyter-core = ">=4.12,<5.0.0 || >=5.1.0" -python-dateutil = ">=2.8.2" -pyzmq = ">=23.0" -tornado = ">=6.2" -traitlets = ">=5.3" +importlib-metadata = {version = ">=4.11.4", markers = "python_version < \"3.12\""} +importlib-resources = {version = "*", markers = "python_version < \"3.9\""} +"jaraco.classes" = "*" +jeepney = {version = ">=0.4.2", markers = "sys_platform == \"linux\""} +pywin32-ctypes = {version = ">=0.2.0", markers = "sys_platform == \"win32\""} +SecretStorage = {version = ">=3.2", markers = "sys_platform == \"linux\""} [package.extras] -docs = ["ipykernel", "myst-parser", "pydata-sphinx-theme", "sphinx-autodoc-typehints", "sphinx (>=4)", "sphinxcontrib-github-alt", "sphinxcontrib-spelling"] -test = ["coverage", "ipykernel (>=6.14)", "mypy", "paramiko", "pre-commit", "pytest", "pytest-cov", "pytest-jupyter[client] (>=0.4.1)", "pytest-timeout"] +completion = ["shtab"] +docs = ["sphinx (>=3.5)", "jaraco.packaging (>=9)", "rst.linker (>=1.9)", "furo", "jaraco.tidelift (>=1.4)"] +testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "flake8 (<5)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "pytest-flake8"] [[package]] -name = "jupyter-core" -version = "5.3.0" -description = "Jupyter core package. A base package on which Jupyter projects rely." -category = "dev" +name = "llvmlite" +version = "0.40.1" +description = "lightweight wrapper around basic LLVM functionality" +category = "main" optional = false python-versions = ">=3.8" -[package.dependencies] -platformdirs = ">=2.5" -pywin32 = {version = ">=300", markers = "sys_platform == \"win32\" and platform_python_implementation != \"PyPy\""} -traitlets = ">=5.3" - -[package.extras] -docs = ["myst-parser", "sphinx-autodoc-typehints", "sphinxcontrib-github-alt", "sphinxcontrib-spelling", "traitlets"] -test = ["ipykernel", "pre-commit", "pytest", "pytest-cov", "pytest-timeout"] +[[package]] +name = "lockfile" +version = "0.12.2" +description = "Platform-independent file locking module" +category = "dev" +optional = false +python-versions = "*" [[package]] -name = "jupyter-events" -version = "0.6.3" -description = "Jupyter Event System library" +name = "more-itertools" +version = "9.1.0" +description = "More routines for operating on iterables, beyond itertools" category = "dev" optional = false python-versions = ">=3.7" -[package.dependencies] -jsonschema = {version = ">=3.2.0", extras = ["format-nongpl"]} -python-json-logger = ">=2.0.4" -pyyaml = ">=5.3" -rfc3339-validator = "*" -rfc3986-validator = ">=0.1.1" -traitlets = ">=5.3" - -[package.extras] -cli = ["click", "rich"] -docs = ["jupyterlite-sphinx", "myst-parser", "pydata-sphinx-theme", "sphinxcontrib-spelling"] -test = ["click", "coverage", "pre-commit", "pytest-asyncio (>=0.19.0)", "pytest-console-scripts", "pytest-cov", "pytest (>=7.0)", "rich"] - [[package]] -name = "jupyter-hdfscontents" -version = "0.2" -description = "Jupyter content manager that uses the HDFS filesystem" +name = "msgpack" +version = "1.0.5" +description = "MessagePack serializer" category = "dev" optional = false python-versions = "*" -[package.dependencies] -hdfs3 = "*" -ipython_genutils = "*" -nbformat = "*" -notebook = "*" -tornado = "*" -traitlets = "*" - [[package]] -name = "jupyter-server" -version = "2.6.0" -description = "The backend—i.e. core services, APIs, and REST endpoints—to Jupyter web applications." +name = "nox" +version = "2023.4.22" +description = "Flexible test automation." category = "dev" optional = false -python-versions = ">=3.8" +python-versions = ">=3.7" [package.dependencies] -anyio = ">=3.1.0" -argon2-cffi = "*" -jinja2 = "*" -jupyter-client = ">=7.4.4" -jupyter-core = ">=4.12,<5.0.0 || >=5.1.0" -jupyter-events = ">=0.6.0" -jupyter-server-terminals = "*" -nbconvert = ">=6.4.4" -nbformat = ">=5.3.0" -overrides = "*" -packaging = "*" -prometheus-client = "*" -pywinpty = {version = "*", markers = "os_name == \"nt\""} -pyzmq = ">=24" -send2trash = "*" -terminado = ">=0.8.3" -tornado = ">=6.2.0" -traitlets = ">=5.6.0" -websocket-client = "*" +argcomplete = ">=1.9.4,<4.0" +colorlog = ">=2.6.1,<7.0.0" +packaging = ">=20.9" +virtualenv = ">=14" [package.extras] -docs = ["ipykernel", "jinja2", "jupyter-client", "jupyter-server", "myst-parser", "nbformat", "prometheus-client", "pydata-sphinx-theme", "send2trash", "sphinx-autodoc-typehints", "sphinxcontrib-github-alt", "sphinxcontrib-openapi (>=0.8.0)", "sphinxcontrib-spelling", "sphinxemoji", "tornado", "typing-extensions"] -test = ["ipykernel", "pre-commit", "pytest-console-scripts", "pytest-jupyter[server] (>=0.4)", "pytest-timeout", "pytest (>=7.0)", "requests"] +tox_to_nox = ["jinja2", "tox (<4)"] [[package]] -name = "jupyter-server-terminals" -version = "0.4.4" -description = "A Jupyter Server Extension Providing Terminals." +name = "nox-poetry" +version = "1.0.2" +description = "nox-poetry" category = "dev" optional = false -python-versions = ">=3.8" +python-versions = ">=3.7,<4.0" [package.dependencies] -pywinpty = {version = ">=2.0.3", markers = "os_name == \"nt\""} -terminado = ">=0.8.3" +nox = ">=2020.8.22" +packaging = ">=20.9" +tomlkit = ">=0.7" -[package.extras] -docs = ["jinja2", "jupyter-server", "mistune (<3.0)", "myst-parser", "nbformat", "packaging", "pydata-sphinx-theme", "sphinxcontrib-github-alt", "sphinxcontrib-openapi", "sphinxcontrib-spelling", "sphinxemoji", "tornado"] -test = ["coverage", "jupyter-server (>=2.0.0)", "pytest-cov", "pytest-jupyter[server] (>=0.5.3)", "pytest-timeout", "pytest (>=7.0)"] +[[package]] +name = "numba" +version = "0.57.1" +description = "compiling Python code using LLVM" +category = "main" +optional = false +python-versions = ">=3.8" + +[package.dependencies] +importlib-metadata = {version = "*", markers = "python_version < \"3.9\""} +llvmlite = ">=0.40.0dev0,<0.41" +numpy = ">=1.21,<1.25" [[package]] -name = "jupyterlab-pygments" -version = "0.2.2" -description = "Pygments theme using JupyterLab CSS variables" -category = "dev" +name = "numpy" +version = "1.24.3" +description = "Fundamental package for array computing in Python" +category = "main" optional = false -python-versions = ">=3.7" - -[[package]] -name = "keyring" -version = "23.13.1" -description = "Store and access your passwords safely." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -importlib-metadata = {version = ">=4.11.4", markers = "python_version < \"3.12\""} -importlib-resources = {version = "*", markers = "python_version < \"3.9\""} -"jaraco.classes" = "*" -jeepney = {version = ">=0.4.2", markers = "sys_platform == \"linux\""} -pywin32-ctypes = {version = ">=0.2.0", markers = "sys_platform == \"win32\""} -SecretStorage = {version = ">=3.2", markers = "sys_platform == \"linux\""} - -[package.extras] -completion = ["shtab"] -docs = ["sphinx (>=3.5)", "jaraco.packaging (>=9)", "rst.linker (>=1.9)", "furo", "jaraco.tidelift (>=1.4)"] -testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "flake8 (<5)", "pytest-cov", "pytest-enabler (>=1.3)", "pytest-black (>=0.3.7)", "pytest-mypy (>=0.9.1)", "pytest-flake8"] - -[[package]] -name = "kiwisolver" -version = "1.4.4" -description = "A fast implementation of the Cassowary constraint solver" -category = "dev" -optional = false -python-versions = ">=3.7" - -[[package]] -name = "llvmlite" -version = "0.40.0" -description = "lightweight wrapper around basic LLVM functionality" -category = "main" -optional = false -python-versions = ">=3.8" - -[[package]] -name = "lockfile" -version = "0.12.2" -description = "Platform-independent file locking module" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "markupsafe" -version = "2.1.3" -description = "Safely add untrusted strings to HTML/XML markup." -category = "dev" -optional = false -python-versions = ">=3.7" - -[[package]] -name = "matplotlib" -version = "3.7.1" -description = "Python plotting package" -category = "dev" -optional = false -python-versions = ">=3.8" - -[package.dependencies] -contourpy = ">=1.0.1" -cycler = ">=0.10" -fonttools = ">=4.22.0" -importlib-resources = {version = ">=3.2.0", markers = "python_version < \"3.10\""} -kiwisolver = ">=1.0.1" -numpy = ">=1.20" -packaging = ">=20.0" -pillow = ">=6.2.0" -pyparsing = ">=2.3.1" -python-dateutil = ">=2.7" -setuptools_scm = ">=7" - -[[package]] -name = "matplotlib-inline" -version = "0.1.6" -description = "Inline Matplotlib backend for Jupyter" -category = "dev" -optional = false -python-versions = ">=3.5" - -[package.dependencies] -traitlets = "*" - -[[package]] -name = "mistune" -version = "2.0.5" -description = "A sane Markdown parser with useful plugins and renderers" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "more-itertools" -version = "9.1.0" -description = "More routines for operating on iterables, beyond itertools" -category = "dev" -optional = false -python-versions = ">=3.7" - -[[package]] -name = "msgpack" -version = "1.0.5" -description = "MessagePack serializer" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "nbclassic" -version = "1.0.0" -description = "Jupyter Notebook as a Jupyter Server extension." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -argon2-cffi = "*" -ipykernel = "*" -ipython-genutils = "*" -jinja2 = "*" -jupyter-client = ">=6.1.1" -jupyter-core = ">=4.6.1" -jupyter-server = ">=1.8" -nbconvert = ">=5" -nbformat = "*" -nest-asyncio = ">=1.5" -notebook-shim = ">=0.2.3" -prometheus-client = "*" -pyzmq = ">=17" -Send2Trash = ">=1.8.0" -terminado = ">=0.8.3" -tornado = ">=6.1" -traitlets = ">=4.2.1" - -[package.extras] -docs = ["sphinx", "nbsphinx", "sphinxcontrib-github-alt", "sphinx-rtd-theme", "myst-parser"] -json-logging = ["json-logging"] -test = ["pytest", "coverage", "requests", "testpath", "nbval", "pytest-playwright", "pytest-cov", "pytest-jupyter", "pytest-tornasync", "requests-unixsocket"] - -[[package]] -name = "nbclient" -version = "0.8.0" -description = "A client library for executing notebooks. Formerly nbconvert's ExecutePreprocessor." -category = "dev" -optional = false -python-versions = ">=3.8.0" - -[package.dependencies] -jupyter-client = ">=6.1.12" -jupyter-core = ">=4.12,<5.0.0 || >=5.1.0" -nbformat = ">=5.1" -traitlets = ">=5.4" - -[package.extras] -dev = ["pre-commit"] -docs = ["autodoc-traits", "mock", "moto", "myst-parser", "nbclient", "sphinx-book-theme", "sphinx (>=1.7)", "sphinxcontrib-spelling"] -test = ["flaky", "ipykernel (>=6.19.3)", "ipython", "ipywidgets", "nbconvert (>=7.0.0)", "pytest-asyncio", "pytest-cov (>=4.0)", "pytest (>=7.0)", "testpath", "xmltodict"] - -[[package]] -name = "nbconvert" -version = "7.4.0" -description = "Converting Jupyter Notebooks" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -beautifulsoup4 = "*" -bleach = "*" -defusedxml = "*" -importlib-metadata = {version = ">=3.6", markers = "python_version < \"3.10\""} -jinja2 = ">=3.0" -jupyter-core = ">=4.7" -jupyterlab-pygments = "*" -markupsafe = ">=2.0" -mistune = ">=2.0.3,<3" -nbclient = ">=0.5.0" -nbformat = ">=5.1" -packaging = "*" -pandocfilters = ">=1.4.1" -pygments = ">=2.4.1" -tinycss2 = "*" -traitlets = ">=5.0" - -[package.extras] -all = ["nbconvert"] -docs = ["ipykernel", "ipython", "myst-parser", "nbsphinx (>=0.2.12)", "pydata-sphinx-theme", "sphinx (==5.0.2)", "sphinxcontrib-spelling"] -qtpdf = ["nbconvert"] -qtpng = ["pyqtwebengine (>=5.15)"] -serve = ["tornado (>=6.1)"] -test = ["ipykernel", "ipywidgets (>=7)", "pre-commit", "pytest", "pytest-dependency"] -webpdf = ["pyppeteer (>=1,<1.1)"] - -[[package]] -name = "nbformat" -version = "5.9.0" -description = "The Jupyter Notebook format" -category = "dev" -optional = false -python-versions = ">=3.8" - -[package.dependencies] -fastjsonschema = "*" -jsonschema = ">=2.6" -jupyter-core = "*" -traitlets = ">=5.1" - -[package.extras] -docs = ["myst-parser", "pydata-sphinx-theme", "sphinx", "sphinxcontrib-github-alt", "sphinxcontrib-spelling"] -test = ["pep440", "pre-commit", "pytest", "testpath"] - -[[package]] -name = "nest-asyncio" -version = "1.5.6" -description = "Patch asyncio to allow nested event loops" -category = "dev" -optional = false -python-versions = ">=3.5" - -[[package]] -name = "notebook" -version = "6.5.4" -description = "A web-based notebook environment for interactive computing" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -argon2-cffi = "*" -ipykernel = "*" -ipython-genutils = "*" -jinja2 = "*" -jupyter-client = ">=5.3.4" -jupyter-core = ">=4.6.1" -nbclassic = ">=0.4.7" -nbconvert = ">=5" -nbformat = "*" -nest-asyncio = ">=1.5" -prometheus-client = "*" -pyzmq = ">=17" -Send2Trash = ">=1.8.0" -terminado = ">=0.8.3" -tornado = ">=6.1" -traitlets = ">=4.2.1" - -[package.extras] -docs = ["sphinx", "nbsphinx", "sphinxcontrib-github-alt", "sphinx-rtd-theme", "myst-parser"] -json-logging = ["json-logging"] -test = ["pytest", "coverage", "requests", "testpath", "nbval", "selenium (==4.1.5)", "pytest-cov", "requests-unixsocket"] - -[[package]] -name = "notebook-shim" -version = "0.2.3" -description = "A shim layer for notebook traits and config" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -jupyter-server = ">=1.8,<3" - -[package.extras] -test = ["pytest", "pytest-console-scripts", "pytest-jupyter", "pytest-tornasync"] - -[[package]] -name = "numba" -version = "0.57.0" -description = "compiling Python code using LLVM" -category = "main" -optional = false -python-versions = ">=3.8" - -[package.dependencies] -importlib-metadata = {version = "*", markers = "python_version < \"3.9\""} -llvmlite = ">=0.40.0dev0,<0.41" -numpy = ">=1.21,<1.25" - -[[package]] -name = "numpy" -version = "1.24.3" -description = "Fundamental package for array computing in Python" -category = "main" -optional = false -python-versions = ">=3.8" - -[[package]] -name = "overrides" -version = "7.3.1" -description = "A decorator to automatically detect mismatch when overriding a method." -category = "dev" -optional = false -python-versions = ">=3.6" +python-versions = ">=3.8" [[package]] name = "packaging" @@ -1095,26 +432,6 @@ category = "dev" optional = false python-versions = ">=3.7" -[[package]] -name = "pandocfilters" -version = "1.5.0" -description = "Utilities for writing pandoc filters in python" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[[package]] -name = "parso" -version = "0.8.3" -description = "A Python Parser" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -qa = ["flake8 (==3.8.3)", "mypy (==0.782)"] -testing = ["docopt", "pytest (<6.0.0)"] - [[package]] name = "pexpect" version = "4.8.0" @@ -1126,26 +443,6 @@ python-versions = "*" [package.dependencies] ptyprocess = ">=0.5" -[[package]] -name = "pickleshare" -version = "0.7.5" -description = "Tiny 'shelve'-like database with concurrency support" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "pillow" -version = "9.5.0" -description = "Python Imaging Library (Fork)" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["furo", "olefile", "sphinx (>=2.4)", "sphinx-copybutton", "sphinx-inline-tabs", "sphinx-removed-in", "sphinxext-opengraph"] -tests = ["check-manifest", "coverage", "defusedxml", "markdown2", "olefile", "packaging", "pyroma", "pytest", "pytest-cov", "pytest-timeout"] - [[package]] name = "pkginfo" version = "1.9.6" @@ -1167,15 +464,15 @@ python-versions = ">=3.6" [[package]] name = "platformdirs" -version = "3.5.1" +version = "3.7.0" description = "A small Python package for determining appropriate platform-specific dirs, e.g. a \"user data dir\"." category = "dev" optional = false python-versions = ">=3.7" [package.extras] -docs = ["furo (>=2023.3.27)", "proselint (>=0.13)", "sphinx-autodoc-typehints (>=1.23,!=1.23.4)", "sphinx (>=6.2.1)"] -test = ["appdirs (==1.4.4)", "covdefaults (>=2.3)", "pytest-cov (>=4)", "pytest-mock (>=3.10)", "pytest (>=7.3.1)"] +docs = ["furo (>=2023.5.20)", "proselint (>=0.13)", "sphinx-autodoc-typehints (>=1.23,!=1.23.4)", "sphinx (>=7.0.1)"] +test = ["appdirs (==1.4.4)", "covdefaults (>=2.3)", "pytest-cov (>=4.1)", "pytest-mock (>=3.10)", "pytest (>=7.3.1)"] [[package]] name = "poetry" @@ -1235,39 +532,6 @@ python-versions = ">=3.7,<4.0" poetry = ">=1.5.0,<2.0.0" poetry-core = ">=1.6.0,<2.0.0" -[[package]] -name = "prometheus-client" -version = "0.17.0" -description = "Python client for the Prometheus monitoring system." -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -twisted = ["twisted"] - -[[package]] -name = "prompt-toolkit" -version = "3.0.38" -description = "Library for building powerful interactive command lines in Python" -category = "dev" -optional = false -python-versions = ">=3.7.0" - -[package.dependencies] -wcwidth = "*" - -[[package]] -name = "psutil" -version = "5.9.5" -description = "Cross-platform lib for process and system monitoring in Python." -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" - -[package.extras] -test = ["ipaddress", "mock", "enum34", "pywin32", "wmi"] - [[package]] name = "ptyprocess" version = "0.7.0" @@ -1276,17 +540,6 @@ category = "dev" optional = false python-versions = "*" -[[package]] -name = "pure-eval" -version = "0.2.2" -description = "Safely evaluate AST nodes without side effects" -category = "dev" -optional = false -python-versions = "*" - -[package.extras] -tests = ["pytest"] - [[package]] name = "pycparser" version = "2.21" @@ -1295,28 +548,6 @@ category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" -[[package]] -name = "pygments" -version = "2.15.1" -description = "Pygments is a syntax highlighting package written in Python." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -plugins = ["importlib-metadata"] - -[[package]] -name = "pyparsing" -version = "3.0.9" -description = "pyparsing module - Classes and methods to define and execute parsing grammars" -category = "dev" -optional = false -python-versions = ">=3.6.8" - -[package.extras] -diagrams = ["railroad-diagrams", "jinja2"] - [[package]] name = "pyproject-hooks" version = "1.0.0" @@ -1336,68 +567,14 @@ category = "dev" optional = false python-versions = ">=3.7" -[[package]] -name = "python-dateutil" -version = "2.8.2" -description = "Extensions to the standard Python datetime module" -category = "dev" -optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,>=2.7" - -[package.dependencies] -six = ">=1.5" - -[[package]] -name = "python-json-logger" -version = "2.0.7" -description = "A python library adding a json log formatter" -category = "dev" -optional = false -python-versions = ">=3.6" - -[[package]] -name = "pywin32" -version = "306" -description = "Python for Window Extensions" -category = "dev" -optional = false -python-versions = "*" - [[package]] name = "pywin32-ctypes" -version = "0.2.0" -description = "" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "pywinpty" -version = "2.0.10" -description = "Pseudo terminal support for Windows from Python." -category = "dev" -optional = false -python-versions = ">=3.7" - -[[package]] -name = "pyyaml" -version = "6.0" -description = "YAML parser and emitter for Python" +version = "0.2.1" +description = "A (partial) reimplementation of pywin32 using ctypes/cffi" category = "dev" optional = false python-versions = ">=3.6" -[[package]] -name = "pyzmq" -version = "25.1.0" -description = "Python bindings for 0MQ" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.dependencies] -cffi = {version = "*", markers = "implementation_name == \"pypy\""} - [[package]] name = "rapidfuzz" version = "2.15.1" @@ -1438,25 +615,6 @@ python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*" [package.dependencies] requests = ">=2.0.1,<3.0.0" -[[package]] -name = "rfc3339-validator" -version = "0.1.4" -description = "A pure python RFC3339 validator" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - -[package.dependencies] -six = "*" - -[[package]] -name = "rfc3986-validator" -version = "0.1.1" -description = "Pure python rfc3986 validator" -category = "dev" -optional = false -python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*" - [[package]] name = "secretstorage" version = "3.3.3" @@ -1469,36 +627,6 @@ python-versions = ">=3.6" cryptography = ">=2.0" jeepney = ">=0.6" -[[package]] -name = "send2trash" -version = "1.8.2" -description = "Send file to trash natively under Mac OS X, Windows and Linux" -category = "dev" -optional = false -python-versions = "!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,>=2.7" - -[package.extras] -nativelib = ["pyobjc-framework-cocoa", "pywin32"] -objc = ["pyobjc-framework-cocoa"] -win32 = ["pywin32"] - -[[package]] -name = "setuptools-scm" -version = "7.1.0" -description = "the blessed package to manage your versions by scm tags" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -packaging = ">=20.0" -tomli = {version = ">=1.0.0", markers = "python_version < \"3.11\""} -typing-extensions = "*" - -[package.extras] -test = ["pytest (>=6.2)", "virtualenv (>20)"] -toml = ["setuptools (>=42)"] - [[package]] name = "shellingham" version = "1.5.1" @@ -1515,70 +643,6 @@ category = "dev" optional = false python-versions = ">=2.7, !=3.0.*, !=3.1.*, !=3.2.*" -[[package]] -name = "sniffio" -version = "1.3.0" -description = "Sniff out which async library your code is running under" -category = "dev" -optional = false -python-versions = ">=3.7" - -[[package]] -name = "soupsieve" -version = "2.4.1" -description = "A modern CSS selector implementation for Beautiful Soup." -category = "dev" -optional = false -python-versions = ">=3.7" - -[[package]] -name = "stack-data" -version = "0.6.2" -description = "Extract data from python stack frames and tracebacks for informative displays" -category = "dev" -optional = false -python-versions = "*" - -[package.dependencies] -asttokens = ">=2.1.0" -executing = ">=1.2.0" -pure-eval = "*" - -[package.extras] -tests = ["pytest", "typeguard", "pygments", "littleutils", "cython"] - -[[package]] -name = "terminado" -version = "0.17.1" -description = "Tornado websocket backend for the Xterm.js Javascript terminal emulator library." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -ptyprocess = {version = "*", markers = "os_name != \"nt\""} -pywinpty = {version = ">=1.1.0", markers = "os_name == \"nt\""} -tornado = ">=6.1.0" - -[package.extras] -docs = ["myst-parser", "pydata-sphinx-theme", "sphinx"] -test = ["pre-commit", "pytest-timeout", "pytest (>=7.0)"] - -[[package]] -name = "tinycss2" -version = "1.2.1" -description = "A tiny CSS parser" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -webencodings = ">=0.4" - -[package.extras] -doc = ["sphinx", "sphinx-rtd-theme"] -test = ["pytest", "isort", "flake8"] - [[package]] name = "tomli" version = "2.0.1" @@ -1595,26 +659,6 @@ category = "dev" optional = false python-versions = ">=3.7" -[[package]] -name = "tornado" -version = "6.3.2" -description = "Tornado is a Python web framework and asynchronous networking library, originally developed at FriendFeed." -category = "dev" -optional = false -python-versions = ">= 3.8" - -[[package]] -name = "traitlets" -version = "5.9.0" -description = "Traitlets Python configuration system" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["myst-parser", "pydata-sphinx-theme", "sphinx"] -test = ["argcomplete (>=2.0)", "pre-commit", "pytest", "pytest-mock"] - [[package]] name = "trove-classifiers" version = "2023.5.24" @@ -1623,25 +667,6 @@ category = "dev" optional = false python-versions = "*" -[[package]] -name = "typing-extensions" -version = "4.6.3" -description = "Backported and Experimental Type Hints for Python 3.7+" -category = "dev" -optional = false -python-versions = ">=3.7" - -[[package]] -name = "uri-template" -version = "1.2.0" -description = "RFC 6570 URI Template Processor" -category = "dev" -optional = false -python-versions = ">=3.6" - -[package.extras] -dev = ["mypy", "flake8 (<4.0.0)", "flake8-annotations", "flake8-bugbear", "flake8-commas", "flake8-comprehensions", "flake8-continuation", "flake8-datetimez", "flake8-docstrings", "flake8-import-order", "flake8-literal", "flake8-noqa", "flake8-requirements", "flake8-type-annotations", "flake8-use-fstring", "pep8-naming"] - [[package]] name = "urllib3" version = "1.26.16" @@ -1655,22 +680,9 @@ brotli = ["brotlicffi (>=0.8.0)", "brotli (>=1.0.9)", "brotlipy (>=0.6.0)"] secure = ["pyOpenSSL (>=0.14)", "cryptography (>=1.3.4)", "idna (>=2.0.0)", "certifi", "urllib3-secure-extra", "ipaddress"] socks = ["PySocks (>=1.5.6,!=1.5.7,<2.0)"] -[[package]] -name = "versioningit" -version = "2.2.0" -description = "Versioning It with your Version In Git" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.dependencies] -importlib-metadata = {version = ">=3.6", markers = "python_version < \"3.10\""} -packaging = ">=17.1" -tomli = {version = ">=1.2,<3.0", markers = "python_version < \"3.11\""} - [[package]] name = "virtualenv" -version = "20.23.0" +version = "20.23.1" description = "Virtual Python Environment builder" category = "dev" optional = false @@ -1678,32 +690,12 @@ python-versions = ">=3.7" [package.dependencies] distlib = ">=0.3.6,<1" -filelock = ">=3.11,<4" -platformdirs = ">=3.2,<4" +filelock = ">=3.12,<4" +platformdirs = ">=3.5.1,<4" [package.extras] -docs = ["furo (>=2023.3.27)", "proselint (>=0.13)", "sphinx-argparse (>=0.4)", "sphinx (>=6.1.3)", "sphinxcontrib-towncrier (>=0.2.1a0)", "towncrier (>=22.12)"] -test = ["covdefaults (>=2.3)", "coverage-enable-subprocess (>=1)", "coverage (>=7.2.3)", "flaky (>=3.7)", "packaging (>=23.1)", "pytest-env (>=0.8.1)", "pytest-freezegun (>=0.4.2)", "pytest-mock (>=3.10)", "pytest-randomly (>=3.12)", "pytest-timeout (>=2.1)", "pytest (>=7.3.1)", "setuptools (>=67.7.1)", "time-machine (>=2.9)"] - -[[package]] -name = "wcwidth" -version = "0.2.6" -description = "Measures the displayed width of unicode strings in a terminal" -category = "dev" -optional = false -python-versions = "*" - -[[package]] -name = "webcolors" -version = "1.13" -description = "A library for working with the color formats defined by HTML and CSS." -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["furo", "sphinx", "sphinx-copybutton", "sphinx-inline-tabs", "sphinx-notfound-page", "sphinxext-opengraph"] -tests = ["pytest", "pytest-cov"] +docs = ["furo (>=2023.5.20)", "proselint (>=0.13)", "sphinx-argparse (>=0.4)", "sphinx (>=7.0.1)", "sphinxcontrib-towncrier (>=0.2.1a0)", "towncrier (>=23.6)"] +test = ["covdefaults (>=2.3)", "coverage-enable-subprocess (>=1)", "coverage (>=7.2.7)", "flaky (>=3.7)", "packaging (>=23.1)", "pytest-env (>=0.8.1)", "pytest-freezer (>=0.4.6)", "pytest-mock (>=3.10)", "pytest-randomly (>=3.12)", "pytest-timeout (>=2.1)", "pytest (>=7.3.1)", "setuptools (>=67.8)", "time-machine (>=2.9)"] [[package]] name = "webencodings" @@ -1713,19 +705,6 @@ category = "dev" optional = false python-versions = "*" -[[package]] -name = "websocket-client" -version = "1.5.2" -description = "WebSocket client for Python with low level API options" -category = "dev" -optional = false -python-versions = ">=3.7" - -[package.extras] -docs = ["Sphinx (>=3.4)", "sphinx-rtd-theme (>=0.5)"] -optional = ["python-socks", "wsaccel"] -test = ["websockets"] - [[package]] name = "xattr" version = "0.10.1" @@ -1752,142 +731,67 @@ testing = ["pytest (>=6)", "pytest-checkdocs (>=2.4)", "flake8 (<5)", "pytest-co [metadata] lock-version = "1.1" python-versions = "^3.8" -content-hash = "5d72e1ce5fccbe4fa153f3737e71c8845f27b08529923d500e8a7598887d38d9" +content-hash = "9a3a5e1fbabec2dfeaca68207571ed5a8d429e78896d6befe231d68a5d003340" [metadata.files] -anyio = [] -appnope = [] -argon2-cffi = [] -argon2-cffi-bindings = [] -arrow = [] -asttokens = [] +argcomplete = [] attrs = [] -backcall = [] -beautifulsoup4 = [] -bleach = [] build = [] cachecontrol = [] certifi = [] cffi = [] charset-normalizer = [] cleo = [] +click = [] colorama = [] -comm = [] -contourpy = [] +colorlog = [] crashtest = [] cryptography = [] -cycler = [] -debugpy = [] -decorator = [] -defusedxml = [] distlib = [] dulwich = [] -exceptiongroup = [] -executing = [] -fastjsonschema = [] +dunamai = [] filelock = [] -fonttools = [] -fqdn = [] -hdfs3 = [] html5lib = [] idna = [] importlib-metadata = [] importlib-resources = [] installer = [] -ipykernel = [] -ipython = [] -ipython-genutils = [] -isoduration = [] "jaraco.classes" = [] -jedi = [] jeepney = [] -jinja2 = [] -jsonpointer = [] jsonschema = [] -jupyter-client = [] -jupyter-core = [] -jupyter-events = [] -jupyter-hdfscontents = [] -jupyter-server = [] -jupyter-server-terminals = [] -jupyterlab-pygments = [] keyring = [] -kiwisolver = [] llvmlite = [] lockfile = [] -markupsafe = [] -matplotlib = [] -matplotlib-inline = [] -mistune = [] more-itertools = [] msgpack = [] -nbclassic = [] -nbclient = [] -nbconvert = [] -nbformat = [] -nest-asyncio = [] -notebook = [] -notebook-shim = [] +nox = [] +nox-poetry = [] numba = [] numpy = [] -overrides = [] packaging = [] -pandocfilters = [] -parso = [] pexpect = [] -pickleshare = [] -pillow = [] pkginfo = [] pkgutil-resolve-name = [] platformdirs = [] poetry = [] poetry-core = [] poetry-plugin-export = [] -prometheus-client = [] -prompt-toolkit = [] -psutil = [] ptyprocess = [] -pure-eval = [] pycparser = [] -pygments = [] -pyparsing = [] pyproject-hooks = [] pyrsistent = [] -python-dateutil = [] -python-json-logger = [] -pywin32 = [] pywin32-ctypes = [] -pywinpty = [] -pyyaml = [] -pyzmq = [] rapidfuzz = [] requests = [] requests-toolbelt = [] -rfc3339-validator = [] -rfc3986-validator = [] secretstorage = [] -send2trash = [] -setuptools-scm = [] shellingham = [] six = [] -sniffio = [] -soupsieve = [] -stack-data = [] -terminado = [] -tinycss2 = [] tomli = [] tomlkit = [] -tornado = [] -traitlets = [] trove-classifiers = [] -typing-extensions = [] -uri-template = [] urllib3 = [] -versioningit = [] virtualenv = [] -wcwidth = [] -webcolors = [] webencodings = [] -websocket-client = [] xattr = [] zipp = [] diff --git a/pyproject.toml b/pyproject.toml index 92f1eac..d2a338d 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,7 @@ [tool.poetry] name = "pysol" -version = "0.1.0" +# version set in git tag +version = "0.0.0" description = "Code for 2D magnetostatics (aka Solenoids)" authors = ["Darren Garnier "] license = "MIT" @@ -13,22 +14,24 @@ click = "^8.0" [tool.poetry.dev-dependencies] poetry = "^1.4.0" -matplotlib = "^3.7.1" -jupyter-hdfscontents = "^0.2" -versioningit = "^2.2.0" -nox = "^2023.4.22" -nox-poetry = "^0.8.0" +# nox = "^2023.4.22" +nox-poetry = "^1.0.0" +dunamai = "^1.17.0" -[tool.versioningit.vcs] -# The method key: -method = "git" # <- The method name -# Parameters to pass to the method: -match = ["v*"] -default-tag = "0.1.0" +[tool.poetry-dynamic-versioning] +enable = true +metadata = true -[tool.versioningit.write] -file = "src/pysol/_version.py" +[tool.poetry-dynamic-versioning.substitution] +folders = [ + { path = "src" } +] [build-system] -requires = ["poetry-core>=1.0.0"] -build-backend = "poetry.core.masonry.api" +requires = ["poetry-core>=1.0.0", "poetry-dynamic-versioning"] +build-backend = "poetry_dynamic_versioning.backend" + +[tool.black] +extend-exclude = ''' +( src/elliptics.py ) +''' diff --git a/src/pysol/__init__.py b/src/pysol/__init__.py index 49906b4..7deb793 100644 --- a/src/pysol/__init__.py +++ b/src/pysol/__init__.py @@ -1 +1,4 @@ """PySol.""" + +# this gets replaced with the package version during the build process +__version__ = "0.0.0" diff --git a/src/pysol/elliptics.py b/src/pysol/elliptics.py index 568902b..ddbd207 100644 --- a/src/pysol/elliptics.py +++ b/src/pysol/elliptics.py @@ -17,19 +17,10 @@ warning = "Couldn't import Numba. Elliptic integrals will run slower than expected." warn_explicit(warning, RuntimeWarning, "elliptics.py", 0) - - def vectorize(*args, **kwargs): - if len(args) == 1 and len(kwargs) == 0 and callable(args[0]): - # called as @decorator - return args[0] - else: - # called as @decorator(*args, **kwargs) - return lambda f: f - - -def celbd(mc): # noqa: C901 +# fmt: off +def celbd(mc): ''' !--------------------------------------------------------------------------- subroutine celbd(mc,elb,eld) @@ -98,9 +89,9 @@ def celbd(mc): # noqa: C901 elb = 1.e0 eld = 0.3862943611198906188344642429164e0 - 0.5e0 * log(mc) elif mc < 0.1: - nome = mc * (Q1 + mc * (Q2 + mc * (Q3 + mc * (Q4 + mc * (Q5 + mc * (Q6 \ - + mc * (Q7 + mc * (Q8 + mc * (Q9 + mc * (Q10 + mc * (Q11 + mc * (Q12 \ - + mc * (Q13 + mc * (Q14 + mc * (Q15 + mc * Q16))))))))))))))) + nome=mc*(Q1+mc*(Q2+mc*(Q3+mc*(Q4+mc*(Q5+mc*(Q6 \ + +mc*(Q7+mc*(Q8+mc*(Q9+mc*(Q10+mc*(Q11+mc*(Q12 \ + +mc*(Q13+mc*(Q14+mc*(Q15+mc*Q16))))))))))))))) if mc < 0.01: dkkc = mc * (K1 + mc * (K2 + mc * (K3 + mc * (K4 + mc * (K5 + mc * @@ -113,37 +104,37 @@ def celbd(mc): # noqa: C901 # # (K'-1)/(pi/2) # - dkkc = (0.01286425658832983978282698630501405107893e0 - + mx * (0.15647573786069663900214275050014481397750e0 - + mx * (0.11426146079748350067910196981167739749361e0 - + mx * (0.09202724415743445309239690377424239940545e0 - + mx * (0.07843218831801764082998285878311322932444e0 - + mx * (0.06935260142642158347117402021639363379689e0 - + mx * (0.06293203529021269706312943517695310879457e0 - + mx * (0.05821227592779397036582491084172892108196e0 - + mx * (0.26483429894479586582278131697637750604652e0 - + mx * (0.05464909112091564816652510649708377642504e0 - + mx * (0.05191068843704411873477650167894906357568e0 - + mx * (0.04978344771840508342564702588639140680363e0 - + mx * (0.04812375496807025605361215168677991360500e0 - ))))))))))))) + dkkc= 0.01286425658832983978282698630501405107893e0 \ + +mx*(0.26483429894479586582278131697637750604652e0 \ + +mx*(0.15647573786069663900214275050014481397750e0 \ + +mx*(0.11426146079748350067910196981167739749361e0 \ + +mx*(0.09202724415743445309239690377424239940545e0 \ + +mx*(0.07843218831801764082998285878311322932444e0 \ + +mx*(0.06935260142642158347117402021639363379689e0 \ + +mx*(0.06293203529021269706312943517695310879457e0 \ + +mx*(0.05821227592779397036582491084172892108196e0 \ + +mx*(0.05464909112091564816652510649708377642504e0 \ + +mx*(0.05191068843704411873477650167894906357568e0 \ + +mx*(0.04978344771840508342564702588639140680363e0 \ + +mx*(0.04812375496807025605361215168677991360500e0 \ + )))))))))))) # # (K'-E')/(pi/2) # - dddc = (0.02548395442966088473597712420249483947953e0 - + mx * (0.51967384324140471318255255900132590084179e0 - + mx * (0.20644951110163173131719312525729037023377e0 - + mx * (0.13610952125712137420240739057403788152260e0 - + mx * (0.10458014040566978574883406877392984277718e0 - + mx * (0.08674612915759188982465635633597382093113e0 - + mx * (0.07536380269617058326770965489534014190391e0 - + mx * (0.06754544594618781950496091910264174396541e0 - + mx * (0.06190939688096410201497509102047998554900e0 - + mx * (0.05771071515451786553160533778648705873199e0 - + mx * (0.05451217098672207169493767625617704078257e0 - + mx * (0.05204028407582600387265992107877094920787e0 - + mx * (0.05011532514520838441892567405879742720039e0 - ))))))))))))) + dddc= 0.02548395442966088473597712420249483947953e0 \ + +mx*(0.51967384324140471318255255900132590084179e0 \ + +mx*(0.20644951110163173131719312525729037023377e0 \ + +mx*(0.13610952125712137420240739057403788152260e0 \ + +mx*(0.10458014040566978574883406877392984277718e0 \ + +mx*(0.08674612915759188982465635633597382093113e0 \ + +mx*(0.07536380269617058326770965489534014190391e0 \ + +mx*(0.06754544594618781950496091910264174396541e0 \ + +mx*(0.06190939688096410201497509102047998554900e0 \ + +mx*(0.05771071515451786553160533778648705873199e0 \ + +mx*(0.05451217098672207169493767625617704078257e0 \ + +mx*(0.05204028407582600387265992107877094920787e0 \ + +mx*(0.05011532514520838441892567405879742720039e0 \ + )))))))))))) kkc = 1.e0 + dkkc logq2 = -0.5e0 * log(nome) @@ -511,6 +502,7 @@ def celbd(mc): # noqa: C901 +mx*(2.868263194837819660109735981973458220407767e16 \ )))))))))))))))))))) return (elb, eld) +# fmt: on def ellipke(k2): @@ -519,12 +511,15 @@ def ellipke(k2): elb, eld = celbd(mc) return (elb + eld, elb + mc * eld) + def ellipk(k2): k, _e = ellipke(k2) return k + def ellipe(k2): _k, e = ellipke(k2) return e + jit_module(nopython=True, fastmath=True, error_model="numpy") diff --git a/src/pysol/inductance.py b/src/pysol/inductance.py index 3828b8f..45b6843 100644 --- a/src/pysol/inductance.py +++ b/src/pysol/inductance.py @@ -61,6 +61,7 @@ def fake_decorator(f): try: from mpmath import fp, mp + USE_MPMATH = True except (ImportError, ModuleNotFoundError): USE_MPMATH = False @@ -630,25 +631,29 @@ def vertical_force_fil(rzn1, rzn2): z2 = rzn2[1] n1 = rzn1[2] n2 = rzn2[2] - k2 = 4 * r1 * r2 / ((r1 + r2) ** 2 + (z1 - z2) ** 2) - elk, ele = ellipke(k2) - BrAt1 = ( - (z2 - z1) - * ( - (r2**2 + r1**2 + (z2 - z1) ** 2) * ele - - ((r2 - r1) ** 2 + (z2 - z1) ** 2) * elk - ) - ) / ( - 5000000 - * r1 - * ((r2 - r1) ** 2 + (z2 - z1) ** 2) - * np.sqrt((r2 + r1) ** 2 + (z2 - z1) ** 2) - ) + BrAt1 = BrGreen(r1, z1, r2, z2) F = n1 * n2 * 2 * np.pi * r1 * BrAt1 return F +@njit +def radial_force_fil(rzn1, rzn2): + # calculatate the radial force per conductor amp. + # of two filaments defined as r, z, and n. + + r1 = rzn1[0] + r2 = rzn2[0] + z1 = rzn1[1] + z2 = rzn2[1] + n1 = rzn1[2] + n2 = rzn2[2] + + BzAt1 = BzGreen(r1, z1, r2, z2) + F = n1 * n2 * 2 * np.pi * r1 * BzAt1 + return F + + # # Green's functions for filaments # @@ -666,34 +671,24 @@ def AGreen(r, z, a, b): @njit def BrGreen(r, z, a, b): + # Br green's function of a filament with radius a, and z postion b, + # calculated at r,z k2 = 4 * a * r / ((r + a) ** 2 + (z - b) ** 2) elk, ele = ellipke(k2) - br = ( - 2e-7 - * (b - z) - / r - / np.sqrt((a + r) ** 2 + (b - z) ** 2) - * ( - ((a**2 + r**2 + (b - z) ** 2) / ((a - r) ** 2 + (z - b) ** 2)) * ele - - elk - ) - ) - return br + amp = -2e-7 / np.sqrt((r + a) ** 2 + (z - b) ** 2) + Gr = (a**2 + r**2 + (z - b) ** 2) / ((r - a) ** 2 + (z - b) ** 2) + return amp * (z - b) / r * (Gr * ele - elk) @njit def BzGreen(r, z, a, b): + # Bz green's function of a filament with radius a, and z postion b, + # calculated at r,z k2 = 4 * a * r / ((r + a) ** 2 + (z - b) ** 2) elk, ele = ellipke(k2) - bz = ( - -2e-7 - / np.sqrt((a + r) ** 2 + (b - z) ** 2) - * ( - ((a**2 - r**2 - (b - z) ** 2) / ((a - r) ** 2 + (z - b) ** 2)) * ele - + elk - ) - ) - return bz + amp = -2e-7 / np.sqrt((r + a) ** 2 + (z - b) ** 2) + Gz = (a**2 - r**2 - (z - b) ** 2) / ((r - a) ** 2 + (z - b) ** 2) + return amp * (Gz * ele + elk) @njit(parallel=True) @@ -855,7 +850,7 @@ def AGreenFil(fil, r, z, gr): # cant jit this... meshgrid not allowed -def filament_coil(r, z, dr, dz, nt, nr, nz): +def filament_coil(r, z, dr, dz, nt, nr, nz, rot=0): """Create an array of filaments, each with its own radius, height, and amperage. @@ -866,13 +861,18 @@ def filament_coil(r, z, dr, dz, nt, nr, nz): nt : number of turns in coil nr : Number of radial slices nz : Number of vertical slices + rot : Rotation of coil about phi axis Returns: Array of shape (nr*nz) x 3 of R, Z, N for each filament """ - rs = np.linspace(r - dr * (nr - 1) / nr / 2, r + dr * (nr - 1) / nr / 2, nr) - zs = np.linspace(z - dz * (nz - 1) / nz / 2, z + dz * (nz - 1) / nz / 2, nz) - R, Z = np.meshgrid(rs, zs) + rd = np.linspace(-dr * (nr - 1) / nr / 2, dr * (nr - 1) / nr / 2, nr) + zd = np.linspace(-dz * (nz - 1) / nz / 2, dz * (nz - 1) / nz / 2, nz) + Rg, Zg = np.meshgrid(rd, zd) + + R = r + Rg * np.cos(rot) - Zg * np.sin(rot) + Z = z + Rg * np.sin(rot) + Zg * np.cos(rot) + N = np.full_like(R, float(nt) / (nr * nz)) return np.dstack([R, Z, N]).reshape(nr * nz, 3) @@ -895,6 +895,17 @@ def mutual_inductance_of_filaments(f1, f2): return M +@njit(parallel=True) +def self_inductance_by_filaments(f, conductor="round", rc=0, hc=0, wc=0): + L = float(0) + for i in prange(f.shape[0]): + for j in range(f.shape[0]): + if i != j: + L += mutual_inductance_fil(f[i, :], f[j, :]) + L += self_inductance_fil(f[i, :], conductor) + return L + + @njit(parallel=True) def vertical_force_of_filaments(f1, f2): F = float(0) @@ -903,6 +914,7 @@ def vertical_force_of_filaments(f1, f2): F += vertical_force_fil(f1[i, :], f2[j, :]) return F + @njit(parallel=True) def radial_force_of_filaments(f1, f2): F = float(0) @@ -912,7 +924,6 @@ def radial_force_of_filaments(f1, f2): return F - # This is a dictionary based API, making it easier to define coils. # probably it should be made into a proper object class # but really I only use it for benchmarking against LDX values diff --git a/tests/test_elliptics.py b/tests/test_elliptics.py index 1ef284e..2be843b 100644 --- a/tests/test_elliptics.py +++ b/tests/test_elliptics.py @@ -27,6 +27,7 @@ def test_ellipke(self): (0.90, 2.5780921133481733, 1.1047747327040733), (0.95, 2.9083372484445524, 1.0604737277662781), ] + for m, k, e in scipy_data: self.assertAlmostEqual( ellipke(m)[0], k, places=14 diff --git a/tests/test_ldx.py b/tests/test_ldx.py index 6f4defe..bbed21b 100644 --- a/tests/test_ldx.py +++ b/tests/test_ldx.py @@ -1,4 +1,7 @@ -from pysol.inductance import * +import numpy as np + +from pysol.inductance import (FilamentCoil, LLyle4, LLyle6, LLyle6A, LMaxwell, + TotalFz, TotalM0) def run_ldx_tests():