semvec/pypi-packages huggingface dataset:
instadp 1.2.1
Download any users Instagram display picture/profile picture in full quality

# instadp
> Download any users Instagram display picture/profile picture in full quality

[![asciicast](https://asciinema.org/a/210125.svg)](https://asciinema.org/a/210125)

## Installation
### Pip installation

```pip install instadp``` 

### Git installation
```bash
# clone the repo
$ git clone https://github.com/sdushantha/instadp.git

# change the working directory to instadp
$ cd instadp

# install the requirements
$ pip3 install -r requirements.txt
```

## Usage
```
usage: instadp.py [-h] username
```
mysb-reminder 5.1
Remaining data notifications with LINE Notify
Keywords: softbank,scraping,LINE Notify

# mysb-scraping
[MySoftbank](https://www.softbank.jp/mysoftbank/)をスクレイピングして通信データ残量をLINE通知するやつ

## Install 
```
$ pip3 install mysb-reminder
```

## Initialize
```python
import mysoftbank

telnum = "your_phone_number"
password = "your_MySoftbank_password"
line_access_token = "your_line_notify_access_token"

api = mysoftbank.API(telnum=telnum, password=password, line_access_token=line_access_token)
```

## Feature
```python
# データ（使用量、残量、繰越残量、追加量、追加使用量、追加繰越量、追加繰越使用量）の取得
data = api.get_data()
print(data)

# out
{
    'used_data': 6.34,
    'remain_data': 0.02, 
    'step_remain_data': 0.0,
    'additional_data': 1.0,
    'additional_used_data': 0.98,
    'given_data': 0.36, 
    'given_used_data': 0.36
}
```
```python
# lineに通知
status = api.send_message()
print(status)

# out
200
```

## Demo
[サンプルコード](https://github.com/miya/MySB_dataTraffic/blob/master/sample.py)を実行した！

<img src="https://user-images.githubusercontent.com/34241526/80075797-32a4e280-8586-11ea-836b-c4f6cdce72b8.png" width=50%>
estpop 0.0.4
Utility Tools for Population Estimates
Requires Python: >=3.5
Keywords: simulation

**estpop** is a Python package providing population forecasting from historical data. This method is based on cohort change ratio[1].

# Sample Code

## Change Ratio

```python
import numpy as np
import openpyxl
import estpop

sheet = openpyxl.load_workbook('data.xlsx').worksheets[0]

pops = {}
for i in range(1, sheet.max_row):
    code = sheet.cell(i+1, 3).value

    if not code in pops:
        pops[code] = []

    males, females = [], []
    for j in range(29, 50):
        males.append(sheet.cell(i+1, j).value)
        females.append(sheet.cell(i+1, j+22).value)
    pops[code].append([males, females])

ratios = {}
for k, v in pops.items():
    change_ratios, baby_ratios, tail_ratios = [], [], []
    try:
        for i in range(len(v) - 5):
            change_ratio, baby_ratio, tail_ratio = estpop.ratios(v[i], v[i+5])
            change_ratios.append(change_ratio)
            baby_ratios.append(baby_ratio)
            tail_ratios.append(tail_ratio)

        ratios[k] = {
            'change_ratio': np.mean(change_ratios, axis=0).tolist(),
            'baby_ratio': float(np.mean(baby_ratios)),
            'tail_ratio': float(np.mean(tail_ratios))
        }
    except:
        pass
```

## Simulation

```python
import openpyxl
import estpop

f = open('result.csv', mode='w')
f.write('code,year\n')

for k, v in pops.items():
    if k in [411, 421, 521]:
        change_ratio = ratios[0]['change_ratio']
        baby_ratio = ratios[0]['baby_ratio']
        tail_ratio = ratios[0]['tail_ratio']
    else:
        change_ratio = ratios[k]['change_ratio']
        baby_ratio = ratios[k]['baby_ratio']
        tail_ratio = ratios[k]['tail_ratio']

    try:
        year = 2020
        estimates = v[5]

        for i in range(7):
            estimates = estpop.simulate(estimates, change_ratio,
                                        baby_ratio, tail_ratio)
            f.write('%s,%s,%s,%s\n' % (k, year+i*5,
                                       ','.join(map(str, estimates[0])),
                                       ','.join(map(str, estimates[1]))))
    except:
        print(k)

f.close()
```

# References

1. Einoshin SUZUKI, Kaoru MORI, Koichi NAGASE, Masatoshi TAMAMURA, Ikuyo KANEKO: The Development of the Future Predictive Model of 'Potentially Disappearing Neighborhood Associations' Using Demographic Data of the Neighborhood Association Base, Journal of the Japan Association of Regional Development and Vitalization, Vol.6, pp.20-30, 2015.
iaBot 0.0.7
A mini framework for building bots using python and can be served using different ways.
Requires Python: >=3.7.0

# iaBot

iaBot is a Python library for creating simple bots and serving it with the different ways available.


[![PyPI version](https://badge.fury.io/py/iaBot.svg)](https://badge.fury.io/py/iaBot) ![Build](https://github.com/satheesh1997/iaBot/workflows/Build%20&%20Publish/badge.svg)




## Installation

Use the package manager [pip](https://pip.pypa.io/en/stable/) to install iaBot.

```bash
pip install iaBot
```

## A simple bot

```python
from iabot import CreateBot
from iabot.handlers import SystemInformationHandler
from iabot.servers import HttpServer

handlers = [
   SystemInformationHandler
]
bot = CreateBot(
   handlers=handlers
)
bot_server = HttpServer(bot)
bot_server.run()
```

This creates a simple bot that will be listening to HttpRequests on the port 8000. Using any tool available send a post request to http://<your_domain.com>:8000/ with the following data.
```json
{
  "handler": "system",
  "action": "time"
}

```
On successfull request you will get time in the response as json.

### Handlers
These are used to group a set of similar actions. You can create your own handlers by inheriting the base handler.
```python
from iabot.handlers import BaseHandler

class StockHandler(BaseHandler):
    handle = 'stock'

    def get_stocks(self, *args, **kwargs):
      .....
      ....

```

Once you create a handler with the actions you can register it to a bot by adding the handler to the list of handlers.

### Actions
These are functions that a bot can execute to do the job when asked for. In the above StockHandler, get_stocks is an action. The response of all the actions should be a dictionary.

When a request reaches the server it will execute the particular action inside the handler. You can also send some additional data to your actions by passing it as a dict using data key in the request data. Remember a handler should always return a dict.

```json
{
  "handler": "stock",
  "action": "get_stocks",
  "data": {
     "date": "04-5-2010"
   }
}

```

Will be updating more and adding more type of servers to serve the bot.

## Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.

Please make sure to update tests as appropriate.


## -
![Python Powered](https://www.python.org/static/community_logos/python-powered-h-70x91.png)