topojson


Nametopojson JSON
Version 1.8 PyPI version JSON
download
home_pageNone
Summarytopojson - a powerful library to encode geographic data as topology in Python!🌍
upload_time2024-03-20 18:17:10
maintainerNone
docs_urlNone
authorNone
requires_python>=3.8
licenseNone
keywords topojson python github topology geojson
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # topojson

[![PyPI version](https://img.shields.io/pypi/v/topojson.svg)](https://pypi.org/project/topojson)
[![License](https://img.shields.io/badge/License-BSD%203--Clause-blue.svg)](https://opensource.org/licenses/BSD-3-Clause)
[![github actions](https://github.com/mattijn/topojson/workflows/test/badge.svg)](https://github.com/mattijn/topojson/actions?query=workflow%3Atest)
[![Conda version](https://anaconda.org/conda-forge/topojson/badges/version.svg)](https://anaconda.org/conda-forge/topojson)
![shapely 2.0 compliant](https://img.shields.io/badge/shapely%201%20%26%202-compliant-brightgreen)


# Encode spatial data as topology in Python!

Topojson is a library that is capable of creating a topojson encoded format of merely any spatial object in Python.

With topojson it is possible to reduce the size of your spatial data. Mostly by orders of magnitude. It is able to do so through:

- Eliminating redundancy through computation of a topology
- Fixed-precision integer encoding of coordinates and
- Simplification and quantization of arcs

See [Topojson Documentation Site](https://mattijn.github.io/topojson) for all info how to use this package.

## Usage

The package can be used in multiple different ways, with the main purpose to create a TopoJSON topology. 

See the Python [Topojson Documentation Site](https://mattijn.github.io/topojson) for all info or [this Notebook](https://nbviewer.jupyter.org/github/mattijn/topojson/blob/main/notebooks/topojson.ipynb) with some examples, such as the following:

<p align="center">
<a href="https://nbviewer.jupyter.org/github/mattijn/topojson/blob/main/notebooks/topojson.ipynb" target="_blank" rel="noopener noreferrer"><img src="docs/images/africa_simplify.png" alt="click to open notebook" width="600px"></a>
</p>

_Click on the image to go the Notebook Viewer with code-snippets how these images are created or visit the [Topojson Documentation Site](https://mattijn.github.io/topojson)._ 

## Installation

Installation can be done through PyPI by the following command:

```
python -m pip install topojson
```

And through conda using the following command:

```
conda install topojson -c conda-forge
```

This package `topojson` has the following hard dependencies:

- `numpy`
- `shapely`
- `packaging`

Further, optional soft dependencies are:

- `altair` - enlarge the experience by visualizing your TopoJSON output
- `simplification` - more and quicker simplification options
- `geojson` - parse string input with GeoJSON data
- `geopandas` - parse your TopoJSON output directly into a GeoDataFrame
- `ipywidgets` + (lab)extension - make your life complete with the interactive experience

## Get in touch

For now, just use the Github issues. That can be:

- usage questions
- bug reports
- feature suggestions
- or anything related

Finally, see the Python [Topojson Documentation Site](https://mattijn.github.io/topojson) for all info how to use this package.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "topojson",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "topojson, python, github, topology, geojson",
    "author": null,
    "author_email": "Mattijn van Hoek <mattijn@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/15/fe/a87a056155b9cf54f2b1dea55dac6daf7f411c3fdb19c6b3427041cd2f0f/topojson-1.8.tar.gz",
    "platform": null,
    "description": "# topojson\n\n[![PyPI version](https://img.shields.io/pypi/v/topojson.svg)](https://pypi.org/project/topojson)\n[![License](https://img.shields.io/badge/License-BSD%203--Clause-blue.svg)](https://opensource.org/licenses/BSD-3-Clause)\n[![github actions](https://github.com/mattijn/topojson/workflows/test/badge.svg)](https://github.com/mattijn/topojson/actions?query=workflow%3Atest)\n[![Conda version](https://anaconda.org/conda-forge/topojson/badges/version.svg)](https://anaconda.org/conda-forge/topojson)\n![shapely 2.0 compliant](https://img.shields.io/badge/shapely%201%20%26%202-compliant-brightgreen)\n\n\n# Encode spatial data as topology in Python!\n\nTopojson is a library that is capable of creating a topojson encoded format of merely any spatial object in Python.\n\nWith topojson it is possible to reduce the size of your spatial data. Mostly by orders of magnitude. It is able to do so through:\n\n- Eliminating redundancy through computation of a topology\n- Fixed-precision integer encoding of coordinates and\n- Simplification and quantization of arcs\n\nSee [Topojson Documentation Site](https://mattijn.github.io/topojson) for all info how to use this package.\n\n## Usage\n\nThe package can be used in multiple different ways, with the main purpose to create a TopoJSON topology. \n\nSee the Python [Topojson Documentation Site](https://mattijn.github.io/topojson) for all info or [this Notebook](https://nbviewer.jupyter.org/github/mattijn/topojson/blob/main/notebooks/topojson.ipynb) with some examples, such as the following:\n\n<p align=\"center\">\n<a href=\"https://nbviewer.jupyter.org/github/mattijn/topojson/blob/main/notebooks/topojson.ipynb\" target=\"_blank\" rel=\"noopener noreferrer\"><img src=\"docs/images/africa_simplify.png\" alt=\"click to open notebook\" width=\"600px\"></a>\n</p>\n\n_Click on the image to go the Notebook Viewer with code-snippets how these images are created or visit the [Topojson Documentation Site](https://mattijn.github.io/topojson)._ \n\n## Installation\n\nInstallation can be done through PyPI by the following command:\n\n```\npython -m pip install topojson\n```\n\nAnd through conda using the following command:\n\n```\nconda install topojson -c conda-forge\n```\n\nThis package `topojson` has the following hard dependencies:\n\n- `numpy`\n- `shapely`\n- `packaging`\n\nFurther, optional soft dependencies are:\n\n- `altair` - enlarge the experience by visualizing your TopoJSON output\n- `simplification` - more and quicker simplification options\n- `geojson` - parse string input with GeoJSON data\n- `geopandas` - parse your TopoJSON output directly into a GeoDataFrame\n- `ipywidgets` + (lab)extension - make your life complete with the interactive experience\n\n## Get in touch\n\nFor now, just use the Github issues. That can be:\n\n- usage questions\n- bug reports\n- feature suggestions\n- or anything related\n\nFinally, see the Python [Topojson Documentation Site](https://mattijn.github.io/topojson) for all info how to use this package.\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "topojson - a powerful library to encode geographic data as topology in Python!\ud83c\udf0d",
    "version": "1.8",
    "project_urls": {
        "Documentation": "https://mattijn.github.io/topojson",
        "Releases": "https://github.com/mattijn/topojson/releases",
        "Source": "https://github.com/mattijn/topojson"
    },
    "split_keywords": [
        "topojson",
        " python",
        " github",
        " topology",
        " geojson"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "06ab9eef12cf9891aad164b80b366167382032dc93f33a0801a068fb7086178a",
                "md5": "3fcbd0d3c0ba0f383b58f929fd52d402",
                "sha256": "67ac4c6b803ef12fd1f02eb9f66791ba32fbff80e60c05d18a12ad9b88ff493a"
            },
            "downloads": -1,
            "filename": "topojson-1.8-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "3fcbd0d3c0ba0f383b58f929fd52d402",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 82414,
            "upload_time": "2024-03-20T18:17:03",
            "upload_time_iso_8601": "2024-03-20T18:17:03.851272Z",
            "url": "https://files.pythonhosted.org/packages/06/ab/9eef12cf9891aad164b80b366167382032dc93f33a0801a068fb7086178a/topojson-1.8-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "15fea87a056155b9cf54f2b1dea55dac6daf7f411c3fdb19c6b3427041cd2f0f",
                "md5": "809a70a8e2bab7902074f23449223123",
                "sha256": "1363933c31cd9ba3dd9cf9df96bbd3ffe56126bd0396f0295a41b48c5666de08"
            },
            "downloads": -1,
            "filename": "topojson-1.8.tar.gz",
            "has_sig": false,
            "md5_digest": "809a70a8e2bab7902074f23449223123",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 25450812,
            "upload_time": "2024-03-20T18:17:10",
            "upload_time_iso_8601": "2024-03-20T18:17:10.832017Z",
            "url": "https://files.pythonhosted.org/packages/15/fe/a87a056155b9cf54f2b1dea55dac6daf7f411c3fdb19c6b3427041cd2f0f/topojson-1.8.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-03-20 18:17:10",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "mattijn",
    "github_project": "topojson",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "topojson"
}
        
Elapsed time: 0.21072s