semvec/pypi-packages huggingface dataset:
django_settings_helper 1.0.3
A simple django's settings value helper
License: MIT
Keywords: django settings helper

======================
Django Settings Helper
======================

Django Settings Helper helps you get environment variables. It is created for settings of Django framework based projects,
however it can be used generally, without Django.


Simple Usage
------------

get_env
~~~~~~~
get_env gets environment variables by keys, and cast into types other than string, such as integer, or boolean::

    foo = get_env('foo')  # read 'foo'. When not found, None is returned

    # read 'bar'. When not found, 'ImproperlyConfigured' exception is raised.
    # if you're using django, django.core.exceptions.ImproperlyConfigured is raised.
    bar = get_env('bar', strict=True)

    # read 'baz'. If goes strict when DEBUG is False.
    baz = get_env('baz', strict=(not DEBUG), default='baz')

    # read DEBUG. When not found, True is returned.
    # environment variable is casted into True, or False if
    # the value is one of these: True, False, Yes, No, On, Off, 1, 0 (case-insensitive)
    bool_val = get_env('DEBUG', strict=False, default=True, type_cast=bool)

    # type_cast parameter not only supports primitive types such as int, bool, and float
    # but also more complex types like dict, list, and 'json'.
    list_cast = get_env('LIST_CAST', type_cast=list)
    dict_cast = get_env('DICT_CAST', type_cast=dict)
    json_load = get_env('JSON_LOAD', type_cast='json')

env_from_file
~~~~~~~~~~~~~
env_from_file() reads environment variables from path.
Variables should be declared with 'export' keyword, e.g.) export FOO=BAR


import_all
~~~~~~~~~~
import_all imports other packages' variables::

    # file: x.y.z_pkg.py
    def test():
        print('hello!')

    FOO = 'foo'
    BAR = 'bar'
    # end of x.y.z_pkg.py

    # file: foo.py
    import_all('x.y.z_pkg', globals())

    # all variables, functions in 'x.y.z_pkg' are imported into this package.
    test()
    print(FOO)
spidey.py 0.4.5
Web spiders are usually disliked by websites, but useful for recursive API/page downloads for offline analysis.
License: MIT
Keywords: web,api,downloader,spider,crawler

# spidey.py

> Web spiders are usually disliked by websites, but useful for recursive API/page downloads for offline analysis.

## Installation

> Pypi Location: https://pypi.python.org/pypi/spidey.py

- Using Pypi - `pip install spidey`

## Usage

> Run `spidey` for Detailed help.

- `spidey --dir NEW_DIR --filter DOMAIN --url URL [--base BASE_URL]`
- `spidey --dir NEW_DIR --filter DOMAIN --url URL --max MAX_DOWNLOADS`
- Example - `spidey --dir test --filter 'www.google.com' --url 'https://www.google.com/' --max 20`

### More Examples

```
spidey \
	-d test \
	-f 'www.google.com' \
	-u 'https://www.google.com/' \
    -b 'https://www.google.com/' \
	-hh '{"Accept" : "application/json"}' \
	-n 2 \
    -m 10 \
    -s 5
```
```
spidey \
	--dir test \
	--filter 'www.google.com' \
	--url 'https://www.google.com/'' \ \
    --base 'https://www.google.com/
	--headers '{"Accept" : "application/json"}' \
	--depth 2 \
    --max 10 \
    --sleep 5

```
sqre-uservice-metricdeviation 0.0.5
Minimal SQuaRE API wrapper for QA metrics
License: MIT
Keywords: lsst

[![Build Status](https://travis-ci.org/lsst-sqre/sqre-apikit.svg?branch=master)](https://travis-ci.org/lsst-sqre/sqre-apikit)

# sqre-uservice-metricdeviation

LSST DM SQuaRE microservice wrapper for QA metrics; more
generally, a minimal viable example for how to use the `apikit`
interfaces to create a SQuaRE-compliant microservice.

## Usage

Create a Flask app (preferably using :class:`apikit.APIFlask`).  If you
have used `APIFlask`, it will already have a metadata route (but if you
are using Kubernetes ingress, you will want to specify the additional
route behind api.lsst.codes (or wherever) as one of the arguments to
route.

Hook your app up with whatever authenticator to Github it needs (if
any), and whatever secrets the authenticator requires.

If you're planning on hosting in a container via Kubernetes, create a
service and a deployment for it (look in `kubernetes`), and then if you
are standing up the front end too, set up an ingress with TLS
certificate and key.  If one already exists (e.g. `api.lsst.codes`) you
just need to add a path to the existing ingress.
cdo-api-client 1.0.0.dev4
Python interface to the climate data online api
License: MIT
Keywords: weather data,noaa,ncdc,climate data online,

[![PyPI version](https://badge.fury.io/py/cdo-api-client.svg)](https://badge.fury.io/py/cdo-api-client)

# cdo-api-client
Python interface to cdo api. Built to allow quick and easy query for weather
data to pandas dataframe objects.

## Installation
Notes:

Super duper alpha at the moment

```
pip install cdo-api-client
```
or for python3
```
pip3 install cdo-api-client
```

* Read more [here](https://www.ncdc.noaa.gov/cdo-web/webservices/v2#gettingStarted)
* Example usage [here](docs/example/dc_weather_data.py)
zbar-py 1.0.4
zbar package
License: MIT

zbar-py
=======

Introduction
------------

Author: `Zachary Pincus <http://zplab.wustl.edu>`__ zpincus@gmail.com

Contributions: Rounak Singh rounaksingh17@gmail.com (example code and
zbar.misc).

zbar-py is a module (compatible with both Python 2.7 and 3+) that
provides an interface to the `zbar <http://zbar.sourceforge.net>`__
bar-code reading library, which can read most barcode formats as well as
QR codes. Input images must be 2D numpy arrays of type uint8 (i.e. 2D
greyscale images).

The zbar library itself packaged along with zbar-py (it's built as a
python extension), so no external dependencies are required. Building
zbar requires the iconv library to be present, which you almost
certainly have, except if you're on windows. Then you probably will need
to download or build the iconv DLL.
`Here <http://mlocati.github.io/articles/gettext-iconv-windows.html>`__
are pre-built 32- and 64-bit binaries for same.

The python code is under the MIT license, and zbar itself is licensed
under the GNU LGPL version 2.1.

Prerequisites:
--------------

-  iconv -- c library required for building zbar-py; see above
-  numpy -- for running zbar-py
-  pygame -- for examples using a webcam

Simple examples:
----------------

More sophisticated examples can be found in 'examples' directory.

-  Scan for barcodes in a 2D numpy array:

.. code:: python

    import zbar
    image = read_image_into_numpy_array(...) # whatever function you use to read an image file into a numpy array
    scanner = zbar.Scanner()
    results = scanner.scan(image)
    for result in results:
        print(result.type, result.data, result.quality, result.position)

-  Scan for UPC-A barcodes and perform checksum validity test:

.. code:: python

    import zbar
    import zbar.misc
    image = read_image_into_numpy_array(...) # get an image into a numpy array
    scanner = zbar.Scanner()
    results = scanner.scan(image)
    for result in results:
        if result.type == 'UPC-A':
            print(result.data, zbar.misc.upca_is_valid(result.data.decode('ascii')))
onetoonemap 1.0.0
1:1 mapping collection type
License: MIT
Keywords: 1:1 map dict

===========
onetoonemap
===========

This is a python module that implements a 1:1 mapping type - similar to a ``dict``, but as well as looking up values by keys (``m[k] -> v``), you can look up keys by values (``m[v] -> k``). 

Given ``m = OneToOneMap()``, the following constraints are always true:

.. code:: python

    m.get(key) == value
    m.get(value) == key

    m.keys() == set(m.keys())
    m.values() == set(m.values())
    set(m.keys()) & set(m.values()) == set()
    set.(m.keys()).isdisjoint(set(m.values())) == True