eqdsk


Nameeqdsk JSON
Version 0.5.0 PyPI version JSON
download
home_pageNone
SummaryA reader, writer and converter for the eqdsk format
upload_time2024-10-22 09:38:16
maintainerNone
docs_urlNone
authorThe Bluemira Developers
requires_python>=3.10
licenseNone
keywords geqdsk cocos eqdsk tokamak
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # Eqdsk

[![Hatch project](https://img.shields.io/badge/%F0%9F%A5%9A-Hatch-4051b5.svg)](https://github.com/pypa/hatch)
[![linting - Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)
[![Actions status](https://github.com/Fusion-Power-Plant-Framework/eqdsk/actions/workflows/main_and_pr.yml/badge.svg)](https://github.com//Fusion-Power-Plant-Framework/eqdsk/actions)

An EQDSK reader and writer for GEQDSK (more soon), with COCOS identification and conversion.

There is support for writing an eqdsk to a JSON format (which is now preferred).

We have extended the EQDSK standard to optionally allow for the definition of a CoilSet.

## Setup

We are pip installable therefore for the most recent release:

```bash
pip install eqdsk
```

or for the most recent commit

```bash
pip install git+https://github.com/Fusion-Power-Plant-Framework/eqdsk.git
```

For a developer setup please see [CONTRIBUTING.md](CONTRIBUTING.md#setup-with-hatch)

## Basic Usage

To read in an eqdsk (json or eqdsk) in its raw state:

```python
from eqdsk import EQDSKInterface

EQDSKInterface.from_file('file.json', no_cocos=True)
```

To read in an eqdsk file with a known cocos format and convert it to a given cocos format:

```python
EQDSKInterface.from_file('file.eqdsk', from_cocos=11, to_cocos=17)
```

Alternatively if the direction (clockwise or anticlockwise) and the units of phi (V.s or V.s/rad) are known,
the cocos standard will be calculated for you:

```python
EQDSKInterface.from_file('file.eqdsk', clockwise_phi=True, volt_seconds_per_radian=True)
```

## CLI

This package includes a CLI tool for eqdsk exploration.

This can be accessed by running `eqdsk` in the terminal after installing the package (or in the Hatch `cli` environment, see [CONTRIBUTING.md](CONTRIBUTING.md#setup-with-hatch)).

For more information on the CLI tool, run `eqdsk --help`.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "eqdsk",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.10",
    "maintainer_email": null,
    "keywords": "GEQDSK, cocos, eqdsk, tokamak",
    "author": "The Bluemira Developers",
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/a8/32/952de0741c9f826562351872fabad58cb1e0e8b5a0a4fb0b4b3017493eb0/eqdsk-0.5.0.tar.gz",
    "platform": null,
    "description": "# Eqdsk\n\n[![Hatch project](https://img.shields.io/badge/%F0%9F%A5%9A-Hatch-4051b5.svg)](https://github.com/pypa/hatch)\n[![linting - Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)\n[![Actions status](https://github.com/Fusion-Power-Plant-Framework/eqdsk/actions/workflows/main_and_pr.yml/badge.svg)](https://github.com//Fusion-Power-Plant-Framework/eqdsk/actions)\n\nAn EQDSK reader and writer for GEQDSK (more soon), with COCOS identification and conversion.\n\nThere is support for writing an eqdsk to a JSON format (which is now preferred).\n\nWe have extended the EQDSK standard to optionally allow for the definition of a CoilSet.\n\n## Setup\n\nWe are pip installable therefore for the most recent release:\n\n```bash\npip install eqdsk\n```\n\nor for the most recent commit\n\n```bash\npip install git+https://github.com/Fusion-Power-Plant-Framework/eqdsk.git\n```\n\nFor a developer setup please see [CONTRIBUTING.md](CONTRIBUTING.md#setup-with-hatch)\n\n## Basic Usage\n\nTo read in an eqdsk (json or eqdsk) in its raw state:\n\n```python\nfrom eqdsk import EQDSKInterface\n\nEQDSKInterface.from_file('file.json', no_cocos=True)\n```\n\nTo read in an eqdsk file with a known cocos format and convert it to a given cocos format:\n\n```python\nEQDSKInterface.from_file('file.eqdsk', from_cocos=11, to_cocos=17)\n```\n\nAlternatively if the direction (clockwise or anticlockwise) and the units of phi (V.s or V.s/rad) are known,\nthe cocos standard will be calculated for you:\n\n```python\nEQDSKInterface.from_file('file.eqdsk', clockwise_phi=True, volt_seconds_per_radian=True)\n```\n\n## CLI\n\nThis package includes a CLI tool for eqdsk exploration.\n\nThis can be accessed by running `eqdsk` in the terminal after installing the package (or in the Hatch `cli` environment, see [CONTRIBUTING.md](CONTRIBUTING.md#setup-with-hatch)).\n\nFor more information on the CLI tool, run `eqdsk --help`.\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "A reader, writer and converter for the eqdsk format",
    "version": "0.5.0",
    "project_urls": {
        "Documentation": "https://github.com/Fusion-Power-Plant-Framework/eqdsk#readme",
        "Issues": "https://github.com/Fusion-Power-Plant-Framework/eqdsk/issues",
        "Source": "https://github.com/Fusion-Power-Plant-Framework/eqdsk"
    },
    "split_keywords": [
        "geqdsk",
        " cocos",
        " eqdsk",
        " tokamak"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "faa9f984a5ffacd12084f7024ce19b9e087db176aafddd7b0118125025dd0a48",
                "md5": "ac8aca61284cd852d457e573537905be",
                "sha256": "a527bcf20f0505916bfa55d6db21446d2b488e6f13e5dbbfe20cd7c50c14e478"
            },
            "downloads": -1,
            "filename": "eqdsk-0.5.0-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "ac8aca61284cd852d457e573537905be",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.10",
            "size": 29573,
            "upload_time": "2024-10-22T09:38:15",
            "upload_time_iso_8601": "2024-10-22T09:38:15.393513Z",
            "url": "https://files.pythonhosted.org/packages/fa/a9/f984a5ffacd12084f7024ce19b9e087db176aafddd7b0118125025dd0a48/eqdsk-0.5.0-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "a832952de0741c9f826562351872fabad58cb1e0e8b5a0a4fb0b4b3017493eb0",
                "md5": "1bc6c10ad529cbc7012543230b952ad5",
                "sha256": "ab09f2b7869455ea008e236759500c0adb6a0f459a38b4dadff613c1094c5164"
            },
            "downloads": -1,
            "filename": "eqdsk-0.5.0.tar.gz",
            "has_sig": false,
            "md5_digest": "1bc6c10ad529cbc7012543230b952ad5",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.10",
            "size": 279251,
            "upload_time": "2024-10-22T09:38:16",
            "upload_time_iso_8601": "2024-10-22T09:38:16.805272Z",
            "url": "https://files.pythonhosted.org/packages/a8/32/952de0741c9f826562351872fabad58cb1e0e8b5a0a4fb0b4b3017493eb0/eqdsk-0.5.0.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-10-22 09:38:16",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "Fusion-Power-Plant-Framework",
    "github_project": "eqdsk#readme",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "eqdsk"
}
        
Elapsed time: 0.34014s