semvec/pypi-packages huggingface dataset:
python-42 0.1.2
Decorator that runs everything (in its way)
License: MIT
Keywords: decorator

Description
-----------

This decorator comes to the aid of developers in search of an answer.
Yet, sometimes the answer seems meaningless because the beings who
instructed it never actually knew what the Question was. So, in this case,
this decorator returns the answer to the Ultimate Question of Life, the
Universe and Everything.

Installation
------------

    $ pip install python-42

Usage
-----------

.. code:: python

    from _42 import _42

    @_42
    def function(...):
        """Whatever."""
        ...
python-memo 0.1.0
Decorators to memoize function results (also for classes)
License: MIT
Keywords: memo memoize dynamic programming cache decorator instance

Description
-----------

*memoize* and *keyed-memoize* decorators.

- ``memo``: The classical *memoize* decorator. It keeps a cache
  ``args -> result`` so you don't continue to perform the same computations.

- ``keymemo(key)``: This decorator factory act as ``memo`` but it permits to
  specify a ``key`` function that takes the ``args`` of the decorated function
  and computes a ``key`` value to use as key in the cache dictionary. This way
  you can for example use a single value of a dictionary as key of the cache,
  or apply a function before passing something to the cache.

- ``instancememo``: The classical *memoize* decorator that can be applied to
  class functions. It keeps a cache ``args -> result`` so you don't continue
  to perform the same computations. The cache is kept in the class namespace.

- ``instancekeymemo(key)``: This decorator factory works like a combination of
  ``instancememo`` and ``keymemo``, so it allows to specify a function that
  generate the cache key based on the function arguments and can be applied
  to class functions.


Usage
-----

.. code:: python

    from memo import memo

    @memo
    def fibonacci(n):
        if n <= 2:
            return 1
        return fibonacci(n-1) + fibonacci(n-2)

.. code:: python

    from memo import keymemo

    @keymemo(lambda tup: tup[0])
    def function(tup):
        # build a cache based on the first value of a tuple
        ...

Installation
------------

The package has been uploaded to `PyPI`_, so you can install it with pip:

    pip install python-memo


.. _PyPI: https://pypi.python.org/pypi/python-memo
limit 0.2.3
Decorator that limits the calling rate of a function
License: MIT
Keywords: rate ratelimit ratelimiter limit limiting api function

Description
-----------

.. image:: https://raw.githubusercontent.com/enricobacis/limit/master/.screenshot/limit.gif
    :target: https://asciinema.org/a/4f621lbwvpgf91neshex89nrm
    :align: center

This decorator limits the calling rate of the decorated function. This is
useful in conjuction with web API calls, where you often get banned if you
perform more calls than the ones specified in the terms of services.

The rate is ``limit`` over ``every``, where limit is the number of invocation
allowed every ``every`` seconds. ``limit(4, 60)`` creates a decorator that
limits the function calls to *4 per minute*. If not specified, ``every``
defaults to ``1`` second.

.. code:: python

    @limit(4, 60)
    def function(...):
        """never invoke this function more than 4 times per minute."""
        ...

Installation
------------

The package has been uploaded to `PyPI`_, so you can install it with pip:

    pip install limit


.. _PyPI: https://pypi.python.org/pypi/limit
bigstack 0.1.1
Decorator that increase the stack size for a function
License: MIT
Keywords: stack stacksize recursive recursion decorator

Description
-----------

This decorator increases the stack size for the function and its recursion
limit. The function runs in a separated thread with a stack size specified
by the ``stacksize`` parameter (``default: 128MiB``). Also the recursion
limit can be modified by the ``recursionlimit`` parameter (``default: 1M``),
but be aware that this is a variable shared by the whole python environment,
so a subsequent invocation of a decorated function may change it.

.. code:: python

    @bigstack
    def function(...):
        """Highly recursive function."""
        ...

.. code:: python

    @bigstack(stacksize=2 ** 30)    # stack size = 1GB
    def function(...):
        """Highly recursive function."""
        ...

Installation
------------

The package has been uploaded to `PyPI`_, so you can install it with pip:

    pip install bigstack


.. _PyPI: https://pypi.python.org/pypi/bigstack
limix-genetics 0.1.6
Genetic-related tools for Limix.
License: MIT

limix-genetics
==============

|PyPIl| |PyPIv| |Documentation Status|

Genetic-related tools for Limix.

Install
-------

The recommended way of installing it is via
`conda <http://conda.pydata.org/docs/index.html>`__

.. code:: bash

    conda install -c conda-forge limix-genetics

An alternative way would be via pip

.. code:: bash

    pip install limix-genetics

Refer to
`documentation <http://limix-genetics.readthedocs.io/en/latest/>`__ for
more information.

Running the tests
-----------------

After installation, you can test it

::

    python -c "import limix_genetics; limix_genetics.test()"

as long as you have `pytest <http://docs.pytest.org/en/latest/>`__.

Authors
-------

-  **Danilo Horta** - https://github.com/Horta

License
-------

This project is licensed under the MIT License - see the
`LICENSE <LICENSE>`__ file for details

.. |PyPIl| image:: https://img.shields.io/pypi/l/limix-genetics.svg?style=flat-square
   :target: https://pypi.python.org/pypi/limix-genetics/
.. |PyPIv| image:: https://img.shields.io/pypi/v/limix-genetics.svg?style=flat-square
   :target: https://pypi.python.org/pypi/limix-genetics/
.. |Documentation Status| image:: https://readthedocs.org/projects/limix-genetics/badge/?style=flat-square&version=latest
   :target: https://limix-genetics.readthedocs.io/en/latest/
numpy_ringbuffer 0.2.1
Ring buffer implementation for numpy
License: MIT
Keywords: numpy

numpy\_ringbuffer
=================

|Build Status| |codecov|

Ring (aka circular) buffers backed by a numpy array, supporting:

-  Operations from ``collections.deque``
-  ``b.append(val)``
-  ``b.appendleft(val)``
-  ``b.extend(val)``
-  ``b.extendleft(val)``
-  ``b.pop(val)``
-  ``b.popleft(val)``
-  The ``collections.Sequence`` protocol (unoptimized)
-  C-side unwrapping into an array with ``np.array(b)``
-  Arbitrary element dtypes, including extra dimensions like
   ``RingBuffer(N, dtype=(int, 3))``

For example:

.. code:: python

    import numpy as np
    from numpy_ringbuffer import RingBuffer

    r = RingBuffer(capacity=4, dtype=np.bool)
    r.append(True)
    r.appendleft(False)
    print(np.array(r))  # array([False, True])

.. |Build Status| image:: https://travis-ci.org/eric-wieser/numpy_ringbuffer.svg?branch=master
   :target: https://travis-ci.org/eric-wieser/numpy_ringbuffer
.. |codecov| image:: https://codecov.io/gh/eric-wieser/numpy_ringbuffer/branch/master/graph/badge.svg
   :target: https://codecov.io/gh/eric-wieser/numpy_ringbuffer