Name | smartmine JSON |
Version |
1.0.3
JSON |
| download |
home_page | https://smartmine.net |
Summary | Python bindings for the Smartmine API |
upload_time | 2023-11-10 11:09:40 |
maintainer | |
docs_url | None |
author | Smartmine |
requires_python | >=3.0, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.* |
license | MIT |
keywords |
smartmine
api
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
Official Smartmine Bindings for Python
======================================
A Python library for Smartmine's API.
Setup
-----
You can install this package by using the pip tool and installing:
pip install smartmine
Setting up a Smartmine Account
------------------------------
Register for a free Smartmine account at https://ai.smartmine.net/service/computer-vision/image-enhancement
Try Services
------------
The following services are available at Smartmine for you to try via the frontend before integrating with the API:
- `Automated subtitling and translation <https://ai.smartmine.net/service/speech-recognition/captioning>`_
- `Image Enhancement <https://ai.smartmine.net/service/computer-vision/image-enhancement>`_
- `Image Upscaling <https://ai.smartmine.net/service/computer-vision/image-super-resolution>`_
- `Image Sharpening <https://ai.smartmine.net/service/computer-vision/image-deblurring>`_
- `Image De-noising <https://ai.smartmine.net/service/computer-vision/image-denoising>`_
- `Image Restoration <https://ai.smartmine.net/service/computer-vision/image-restoration>`_
Using the Smartmine API
-----------------------
General Usage:
.. code-block:: python
import smartmine
from smartmine import ServiceName
smartmine.username = input("Username: ")
smartmine.password = input("Password: ")
smartmine.process_image(
service_name=ServiceName.image_restoration,
load_path="examples/images/earth.png",
save_path="results/earth_restored.png",
)
Advanced Usage:
.. code-block:: python
import os
from pathlib import Path
import smartmine
from smartmine import ServiceName
smartmine.username = os.environ.get("SMARTMINE_USERNAME")
smartmine.password = os.environ.get("SMARTMINE_PASSWORD")
# Bulk process images
smartmine.bulk_process_images(
service_name=ServiceName.image_restoration,
load_dir="examples/images/",
save_dir=str(Path.home() / "Downloads"),
)
Running Tests
-------------
First, make sure you have your Smartmine username and password ready, then set these as environment variables, i.e.:
export SMARTMINE_USERNAME=<username>
export SMARTMINE_PASSWORD=<password>
Then, use `pytest` to run unit tests:
pytest -vv --exitfirst smartmine/
Raw data
{
"_id": null,
"home_page": "https://smartmine.net",
"name": "smartmine",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.0, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*",
"maintainer_email": "",
"keywords": "smartmine api",
"author": "Smartmine",
"author_email": "info@smartmine.net",
"download_url": "https://files.pythonhosted.org/packages/77/65/107146998096471e61ce181c26fbb321a06ba64e33e7e28c04d4b7c34d62/smartmine-1.0.3.tar.gz",
"platform": null,
"description": "Official Smartmine Bindings for Python\n======================================\n\nA Python library for Smartmine's API.\n\n\nSetup\n-----\n\nYou can install this package by using the pip tool and installing:\n\n pip install smartmine\n\n\n\nSetting up a Smartmine Account\n------------------------------\n\nRegister for a free Smartmine account at https://ai.smartmine.net/service/computer-vision/image-enhancement\n\nTry Services\n------------\n\nThe following services are available at Smartmine for you to try via the frontend before integrating with the API:\n\n- `Automated subtitling and translation <https://ai.smartmine.net/service/speech-recognition/captioning>`_\n- `Image Enhancement <https://ai.smartmine.net/service/computer-vision/image-enhancement>`_\n- `Image Upscaling <https://ai.smartmine.net/service/computer-vision/image-super-resolution>`_\n- `Image Sharpening <https://ai.smartmine.net/service/computer-vision/image-deblurring>`_\n- `Image De-noising <https://ai.smartmine.net/service/computer-vision/image-denoising>`_\n- `Image Restoration <https://ai.smartmine.net/service/computer-vision/image-restoration>`_\n\n\nUsing the Smartmine API\n-----------------------\n\nGeneral Usage:\n\n.. code-block:: python\n\n import smartmine\n from smartmine import ServiceName\n\n smartmine.username = input(\"Username: \")\n smartmine.password = input(\"Password: \")\n\n smartmine.process_image(\n service_name=ServiceName.image_restoration,\n load_path=\"examples/images/earth.png\",\n save_path=\"results/earth_restored.png\",\n )\n\n\nAdvanced Usage:\n\n.. code-block:: python\n\n import os\n from pathlib import Path\n\n import smartmine\n from smartmine import ServiceName\n\n smartmine.username = os.environ.get(\"SMARTMINE_USERNAME\")\n smartmine.password = os.environ.get(\"SMARTMINE_PASSWORD\")\n\n\n # Bulk process images\n smartmine.bulk_process_images(\n service_name=ServiceName.image_restoration,\n load_dir=\"examples/images/\",\n save_dir=str(Path.home() / \"Downloads\"),\n )\n\n\nRunning Tests\n-------------\n\nFirst, make sure you have your Smartmine username and password ready, then set these as environment variables, i.e.:\n\n export SMARTMINE_USERNAME=<username>\n export SMARTMINE_PASSWORD=<password>\n\nThen, use `pytest` to run unit tests:\n\n pytest -vv --exitfirst smartmine/\n",
"bugtrack_url": null,
"license": "MIT",
"summary": "Python bindings for the Smartmine API",
"version": "1.0.3",
"project_urls": {
"Homepage": "https://smartmine.net"
},
"split_keywords": [
"smartmine",
"api"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "a1ff6c34bba54a595793214b45986c4c10d70a88d46424dd69d66c80f120173a",
"md5": "ef0d677228079022cc0f7d0c8a4afa55",
"sha256": "3cc261efa128c015ec088e9a6ddbc1659d4602c5169672bafa73d05f77f89c14"
},
"downloads": -1,
"filename": "smartmine-1.0.3-py2.py3-none-any.whl",
"has_sig": false,
"md5_digest": "ef0d677228079022cc0f7d0c8a4afa55",
"packagetype": "bdist_wheel",
"python_version": "py2.py3",
"requires_python": ">=3.0, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*",
"size": 10073,
"upload_time": "2023-11-10T11:09:39",
"upload_time_iso_8601": "2023-11-10T11:09:39.067320Z",
"url": "https://files.pythonhosted.org/packages/a1/ff/6c34bba54a595793214b45986c4c10d70a88d46424dd69d66c80f120173a/smartmine-1.0.3-py2.py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "7765107146998096471e61ce181c26fbb321a06ba64e33e7e28c04d4b7c34d62",
"md5": "556f28169fc2fcc3f51a06b076da8d19",
"sha256": "6dc055bc51446e2e954cef959a6bda3ada332fca30149283d2383f4c408550a6"
},
"downloads": -1,
"filename": "smartmine-1.0.3.tar.gz",
"has_sig": false,
"md5_digest": "556f28169fc2fcc3f51a06b076da8d19",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.0, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*",
"size": 8462,
"upload_time": "2023-11-10T11:09:40",
"upload_time_iso_8601": "2023-11-10T11:09:40.681830Z",
"url": "https://files.pythonhosted.org/packages/77/65/107146998096471e61ce181c26fbb321a06ba64e33e7e28c04d4b7c34d62/smartmine-1.0.3.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-11-10 11:09:40",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "smartmine"
}