semvec/pypi-packages huggingface dataset:
yoton 0.1.0
Cache decorator to make applying cache less pain
License: MIT

YoTon
=========

.. image:: https://travis-ci.org/ivannotes/yoton.svg?branch=master
    :target: https://travis-ci.org/ivannotes/yoton

YoTon is an util for cache, it simplifies cache with a decorator.

Install
---------------------

.. code-block:: bash

    $ pip install yoton

Configuration
----------------------

.. code-block:: python

    redis_server_config = {
        "default": {
            "host": "localhost",
            "port": 6379,
            "db": 1
        },
        "server_a": {
            "host": "localhost",
            "port": 6378,
            "db": 2,
        }
    }
    yoton = YoTon(redis_server_config)
    
Apply To Function
----------------------

.. code-block:: python

    @yoton.cache(key_pattern="dummy_cache_key", expire_seconds=60)
    def dummy_func():
        return "hello"

    >> dummy_func()  # call the function
    "hello" set in the cache

Key Pattern
----------------------

The cache key is using python's string format syntax, you can find it here

.. code-block:: python

    @youton.cache(key_pattern="dummy:{a}_{b}_{c}", expire_seconds=60)
    def dummy_func_with_params(a, b, c=3):
        return a + b + c

Complex object in parameters

.. code-block:: python

    @youton.cache(key_pattern="dummy:{a.id}_{b.name}", expire_seconds=60)
    def dummy_func_with_params(a, b):
        return a + b

Select Database
----------------------

.. code-block:: python

    @yoton.cache(key_pattern="dummy_cache_key", database="test", expire_seconds=60)
    def dummy_func_database():
        return "hello"

Customized Formatter
---------------------

.. code-block:: python

    @yoton.cache(key_pattern="dummy_cache_key", key_formatter=CustomizedFormatter(), expire_seconds=60)
    def dummy_func_keyforamtter():
        pass

Apply Cache To Instance Method
-------------------------------

.. code-block:: python

    class DummyClass(object):

        @yoton.cache(key_pattern="instance_method")
        def instance_method(self):
            return "hello"

Misc
---------
    
.. code-block:: python

    # call the function directly without touch cache
    dummy_func_with_params.call(a=1, b=2, c=3)

    # refresh cache data
    dummy_func_with_params.refresh_cache(a=1, b=2, c=3)

    # remove data in cache
    dummy_func_with_params.delete_cache(a=1, b=2, c=3)
pygoogling 0.0.2
Python library to do google search
License: MIT
Keywords: google search python module

==========
pygoogling
==========
.. image:: https://www.quantifiedcode.com/api/v1/project/bfbfe707e09b4f109913969336393abf/badge.svg
  :target: https://www.quantifiedcode.com/app/project/bfbfe707e09b4f109913969336393abf
  :alt: Code issues

Using google search engine from python

Tested python version
*********************
- python 2.7.6
- python 3.4.3

Installation
************
.. code-block:: bash

  $ pip install pygoogling

Usage
*****
For now, this library only contain one class, ``GoogleSearch``. Here is a short description to use this library.

.. code-block:: python

  from pygoogling.googling import GoogleSearch


  google_search = GoogleSearch('python')
  google_search.start_search(max_page=3)
  print(google_search.search_result) # will print the url as list of string
  google_search.more_page(4) # to search 4 extra pages
  print(google_search.search_result) # the result will be added to current result

The keyword is the only requirement to initiate this class. The ``max_page`` parameter is used to determine how many google web page result you want to parse. By default, ``max_page`` will be one. The ``GoogleSearch.more_page()`` is a method used to do extra search. The only required parameter is how many more pages you want to get the result of google search.
py-pcha 0.1.2
Python implemenation of PCHA algorithm
License: MIT
Keywords: Archetypal Analysis,AA,PCHA,Clustering,Machine Learning,Signal Processing

Python implementation of Principal Convex Hull Analysis (PCHA). PCHA is an efficient algorithm for finding archetypes in a dataset, developed by M. Mørup and L.K. Hansen and published in the paper Archetypal analysis for machine learning and data mining, Neurocomputing (2012). Continue reading on Github for more info and examples.