Skip to main content

Nozomi Async API for retrieving images, videos, gifs.

Project description

NozomiPy-Async

Async nozomi.la API for Python3.

NozomiPy-Async is an Async Python3 library for nozomi.la API.

NozomiPy-Async also provides a commandline tool to download images and tags from nozomi.la.

Based on Python-Nozomi: https://github.com/Alfa-Q/python-nozomi

Install

pip install nozomipy-async

Import packages

from nozomipy.async_api import api

API Usages

API init

import asyncio
from nozomipy.async_api import api

nozomi_api = api(semaphore=8,proxy="http://127.0.0.1:1080")

Download images

# The tags that the posts retrieved must contain
positive_tags = ['veigar', 'wallpaper']

# Gets all posts with the tags 'veigar', 'wallpaper'
posts = await nozomi_api.get_posts()
# download all images
await asyncio.gather(*[download_img_tags(post,path) for post in posts])

Create dataset

Download images and tags during a period to a folder named with positive tags.

nozomipy --path "./" --positive_tags 'miyase_mahiro' --start_date 2022-02-22 --end_date 2022-01-22 --num_process=8 --proxy http://127.0.0.1:7890

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nozomipy-async-1.0.0.tar.gz (11.9 kB view hashes)

Uploaded Source

Built Distributions

nozomipy_async-1.0.0-py3.9.egg (21.9 kB view hashes)

Uploaded Source

nozomipy_async-1.0.0-py3-none-any.whl (11.4 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page