semvec/pypi-packages huggingface dataset:
asqlite3 0.0.1
An async sqlite3 module
License: MIT
Keywords: sql,sqlite3,asyncio

asqlite3
============

Purpose
-----------

An asynchronous way to connect to an `sqlite3 <https://docs.python.org/3/library/sqlite3.html>`_
database. Normally, this would block the
`asyncio <https://docs.python.org/3/library/asyncio.html>`_ event loop and slow down the execution
speed of the script. This is because asyncio
isn't meant for I/O bound tasks. `threading <https://docs.python.org/3/library/threading.html>`_ is
more efficient for that, which is exactly why this
module uses it under the hood.

Features
----------

* A similar syntax to the ``sqlite3`` module in the Standard library
* Has ``asyncio`` idioms such as ``async for``, ``await``, and ``async with``
* Provides all features of the built-in ``sqlite3`` module

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

Installing ``asqlite3`` should be done through `PIP <https://pypi.org/project/pip/>`_:

.. code:: sh

    $ pip install asqlite3

Make sure you have Python version 3.6+ before installing!

Contributing
--------------

Contributions are always encouraged and open.

Examples
-----------

.. code-block:: python

    import asyncio

    import asqlite3

    conn = asqlite3.connect(':memory:')

    async def connection():
        async with conn:
            await conn.execute("CREATE TABLE table (plate INT)")
            await conn.execute("INSERT INTO table VALUES (5)")
        # connection is automatically closed
    
    loop = asyncio.get_event_loop()
    loop.run_until_complete(connection())

.. code-block:: python

    import asyncio

    import asqlite3

    conn = asqlite3.connect(':memory:')

    async def cursor():
        cur = await conn.cursor()
        rows = [i async for i in cur]
        return rows
    
    loop = asyncio.get_event_loop()
    loop.run_until_complete(cursor())

License
----------

``asqlite`` is currently under the MIT license.
myopy 1.1.2
myopy, run blind python files.
License: MIT
Requires Python: >=3.6,<4.0
Keywords: config,source

[![tests](https://github.com/loiccoyle/myopy/workflows/tests/badge.svg)](https://github.com/loiccoyle/myopy/actions) [![pypi](https://img.shields.io/pypi/v/myopy)](https://pypi.org/project/myopy/)

# myopy

> Run blind python files.

This single class package, provides python objects to a python file at run time. This is ideal for configuration files where the user does not need to know where an object comes from or how to initialize it. It allows the python file to be blind to the origin of it's objects, removing the need for imports, object initializations or convoluted subclassing.

This is pretty much a standalone clone of the way the amazing [qutebrowser](https://github.com/qutebrowser/qutebrowser) handles it's config files.

Feel free to copy paste the `PyFile` class if you don't want the added dependency.

# Installation
```
pip install myopy
```

# Usage

Say you want to allow the user to change a `dict` containing some settings for an application in a configuration file called `config.py`:

In the application you would have something along the lines of:

```python
from myopy import PyFile

user_dict = {'something': 2}

config = PyFile('path/to/config.py')
# we provide the config file the user_dict in the 'settings' variable
config.provide(settings=user_dict)
module = config.run()  # returns a module object
print('after running config: ', user_dict)
print('module: ', module)
```
And in the user facing `config.py`, the `user_dict` object would be provided in the `settings` variable, and the user can change its values at will:
```python
print('in config: ', settings)
settings['something_else'] = 4
settings['something'] = 3
```

The output would be:
```
in config: {'something': 2}
after running config: {'something': 3, 'something_else': 4}
module: <module 'config' from 'path/to/config.py'>
```
the `user_dict` is modified in place.
pycbp 0.2.8
A Library for Constrained Belief Propagation
License: MIT
Requires Python: >=3.7
Keywords: belief propagation bayesian inference

# CBP(Constrained Belief Propagation)

Constrained Belief Progapation is a package for solving inference tasks with collective\aggregate evidence.

## What is collective\aggregate evidence?

Let us consider a task, estimating dymanics of bird migration. We consider the following different kinds of evidence



1. Install trackers for interested birds. So we access to the trajectories of sampled birds. We can query the position of interested birds at any time and how they move.



2. We shoot a video for the birds migration. We can quety the distibution of the birds in the space at any time. However, we do not have access to individual trajectories and how birds move overtime.



The second information is an instance of collective\aggregate evidence, which remove the distinguishability of individuals. 



## Why do we need collective\aggregate evidence?



* Easy and cheap to acquire

* Privacy concern



Sometimes, collective\aggregate evidence is the ony information we access to analysis collective behavior.



## How can we represent the special evidence?



In CBP, we represent the special evidence as a special nodes  in probabilistic graphical model(PGM), named node with fixed marginal constraints.  A hidden markov model with  aggregate evidence can be presented as: 

![image-20200716201949266](https://i.imgur.com/iuuxhT7.png)

The shaded nodes represents the aggregate evidence.  We can introduce a simple version:

![image-20200716202622245](https://i.imgur.com/W7yfLFN.png)

## How to do inference?

In CBP framework, we present a nice elegant connections between multi-marginal optimal transport problems and inference problem for PGM.  We implement algorithms similar to the standard belief propagation. In CBP, we present `Iterative Scaling Belief Propagation` and `Contrained Norm-product` two algorithms. More details can be find the [paper](https://arxiv.org/pdf/2006.14113.pdf).

## Citation

```
@article{haasler2020multi,
  title={Multi-marginal optimal transport and probabilistic graphical models},
  author={Haasler, Isabel and Singh, Rahul and Zhang, Qinsheng and Karlsson, Johan and Chen, Yongxin},
  journal={arXiv preprint arXiv:2006.14113},
  year={2020}
}
```
django-q-rollbar 0.1.3
A Rollbar support plugin for Django Q
License: MIT
Keywords: django distributed task queue worker scheduler cron redis disque ironmq sqs orm mongodb multiprocessing rollbar

# django-q-rollbar
A [Django Q](https://github.com/Koed00/django-q/) Error Reporter plugin adding [Rollbar](https://rollbar.com/) support.

### Installation
This plugin is intended to be included with Django Q as [setuptools extra](https://setuptools.readthedocs.io/en/latest/setuptools.html#declaring-extras-optional-features-with-their-own-dependencies).

`$ pip install django-q[rollbar]`

Or add `django-q[rollbar]` to `requirements.txt`.

> This plugin requires Django Q version 0.8.1 or greater. Earlier versions of Django Q can incorporate rollbar support via the `rollbar` key in the `Q_CLUSTER` settings dictionary.

### Usage
Configure Rollbar via the Django Q `Q_CLUSTER` dictionary in your Django project's `settings.py`. It is important that the `rollbar` key be set in the `error_reporter` dictionary, as this name aligns with the project's entry point for this plugin.
```python
Q_CLUSTER = {
    'error_reporter': {
        'rollbar': {
            'access_token': '32we33a92a5224jiww8982',
            'environment': 'Django-Q'
        }
    }
}
```
Please check the [Pyrollbar configuration reference](https://rollbar.com/docs/notifier/pyrollbar/) for more options. Additional options defined in `Q_CLUSTER` are passed directly as kwargs to Pyrollbar's `rollbar.init`.

Of course, you will need a Rollbar account and access token to use this plugin.
aurora-term 0.1.0
AWS Aurora Serverless interactive terminal
License: MIT
Requires Python: >=3.7,<4.0
Keywords: aws,aurora,data-api,cli

aurora-term
===========

AWS Aurora Serverless interactive terminal.

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

The **aurora-term** app allows you to run SQL statements against `Aurora Serverless`_ databases without establishing a persistent connection, this is easily achieved thanks to the `Data-API`_.

Besides the non-persistent connection it works just as any other interactive terminal like `mysql-cli`_ and `psql`_.

Requirements
------------

- Python 3 and Pip.
- An AWS IAM user `authorized`_ to access the Data API (with the *AmazonRDSDataFullAccess* policy for example).
- Access key and secret access key properly configured for the same user (it can be done using the `aws-cli`_).

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

The easiest and recommended way to install it is using Pip. ::

  pip install aurora-term

Usage
-----

Just specify the database cluster ARN, the secret manager ARN and the database name. ::

  aurora-term --cluster="arn:aws:rds:..." --secret="arn:aws:secretsmanager:..." mydb

**TIP:**

There are a few environment variables that might come in handy, you can set them to avoid the need to pass all the credentials when starting **aurora-term**.

- **AWS_PROFILE** Profile to be used.
- **RDS_CLUSTER_ARN** Aurora cluster ARN.
- **RDS_SECRET_ARN** Secret manager ARN.
- **RDS_DB_NAME** Database name.

e.g. ::

  export RDS_CLUSTER_ARN="arn:aws:rds:..."
  export RDS_SECRET_ARN="arn:aws:secretsmanager:..."

  aurora-term mydb

The interactive terminal looks like as follow. ::

  aurora-term (0.1.0)
  Type "help" or "?" for help.

  mydb=#

For more usage details. ::

  aurora-term -h


.. _Aurora Serverless: https://aws.amazon.com/rds/aurora/
.. _Data-API: https://docs.aws.amazon.com/AmazonRDS/latest/AuroraUserGuide/data-api.html
.. _mysql-cli: https://dev.mysql.com/doc/refman/5.5/en/mysql.html
.. _psql: https://www.postgresql.org/docs/current/app-psql.html
.. _authorized: https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies.html
.. _aws-cli: https://docs.aws.amazon.com/cli/latest/userguide/cli-chap-welcome.html
B3Bovespa 0.1.1
Package for web-scrapping companies from B3Bovespa
License: MIT
Keywords: b3,bovespa,web,scrap,company,stock,market

# B3Bovespa

This repository scraps all the companies listed on the Bovespa B3 using 
[Selenium](https://selenium-python.readthedocs.io).

## Drivers

To allow web scrapping, it is necessary to download the driver accordingly to your preferred
browser. Currently, the only supported browsers are *Chrome* and *Firefox*.

* [Chrome's chromedriver](https://sites.google.com/a/chromium.org/chromedriver/downloads)
* [Firefox's geckodriver](https://github.com/mozilla/geckodriver/releases)

It is necessary that the *driver's* version is compatible with the current version
of the installed browser. 

## Installation

The package could be installed via `pip`

```bash
pip install b3bovespa
```

It will install as dependencies [Selenium](https://github.com/baijum/selenium-python) (used for the web scrapping), 
[Pandas](https://github.com/pandas-dev/pandas) (used to handle the output data) and 
[tqdm](https://github.com/tqdm/tqdm) (used for progress tracking).

 ## Usage
 
 `B3Bovespa` package is based on the `B3Scrapper` class, which will control the web scrapping of the Bovespa website.
 The web-scrapping is really straight-forward, you will need to instantiate a `B3Bovespa` object, passing
 the path of the browser driver (as discussed in [here](#Drivers)), the chosen driver (`B3Bovespa` supports both Firefox
 and Chrome) and the output path to export the company list on a CSV format.
 
```python
from b3bovespa import B3Scrapper

DRIVER_PATH = 'path/to/drive'
b3 = B3Scrapper(path=DRIVER_PATH, browser="Chrome", output_path="/usr/companies/")
```

With the `B3Scrapper` object, it is simple to get the information from all the companies listed on Bovespa,
a simple call to `get_companies_data()` will return a Pandas Dataframe containing all the info.

The `get_companies_data()` will also save a `csv` file containing all the information on the output
path given to the object. If no output path was given, it will just save a `csv` file on the file directory.

```python
companies = b3.get_companies_data()
```

If necessary, it is possible to close the current session of the driver by calling the `close()` method.

```python
b3.close()
```

# Change Log

## [0.1] - 2020-08-18
- Creating the base code for web scrapping
- Adding *Chrome* and *Firefox* support
- Adding [B3Bovespa]('http://www.b3.com.br/pt_br/produtos-e-servicos/negociacao/renda-variavel/empresas-listadas.htm') 
as base website for scrapping
- Adding `tqdm` progress bar to keep track

## [0.1.1] - 2020-08-20
- Bug fixes: fixing broken import
iscomputeron 1.0
checks if your computer is on in python!
License: MIT
Keywords: PYTHON,COMPUTER,ON

Is Computer On

==============



Installing:



.. code:: sh



    pip install iscomputeron

    python3 -m pip install -U iscomputeron



Importing:



.. code:: py



    from iscomputeron import is_computer_on, is_computer_off



Usage:



.. code:: py



    is_computer_on() #returns True

    is_computer_off() #returns False



License

=======



MIT License



Copyright (c) 2020 RandomKiddo



Permission is hereby granted, free of charge, to any person obtaining a

copy of this software and associated documentation files (the

"Software"), to deal in the Software without restriction, including

without limitation the rights to use, copy, modify, merge, publish,

distribute, sublicense, and/or sell copies of the Software, and to

permit persons to whom the Software is furnished to do so, subject to

the following conditions:



The above copyright notice and this permission notice shall be included

in all copies or substantial portions of the Software.



THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS

OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF

MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.

IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY

CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,

TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE

SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.