semvec/pypi-packages huggingface dataset:
floatrange 1.0
Support of range() generator with floats.
License: MIT
Keywords: range,float,computing,generator,loop

floatrange
==========

:author: Laurent Pointal <laurent.pointal@laposte.net>
:copyright: Laurent Pointal - 2011-2015
:license: MIT
:version: 1.0

`Module documentation <http://floatrange.readthedocs.org/>`_

`Mercurial repository & bug tracking <http://sourceforge.net/projects/floatrange/>`_
(on SourceForge).

`Developer page <https://perso.limsi.fr/pointal/python:floatrange>`_

What is it?
-----------

A simple module providing a ``floatrange()`` to build generators
providing a range like interface for floating point numbers.
As floating point computation may not be exact, these generators
support a precision ``prec`` parameter to define how near a value
correspond to a value in the range.

Installation
------------

Unless someone built a package for your OS distro, the simplest procedure
is to use ``pip`` to install the module:

    pip install floatrange

If you have no admin access to install things on you computer, you may install
a virtualenv and run pip inside this virtual env, or you can do a local user
installation:

    pip install --user floatrange
pandas-redistrict 0.0.3
Redistricting of pandas dataframes
License: MIT

# pandas-redistrict

Uses data on redistricting to apply redistricting to older datasets to represent the districts in their current state.

Supports merging and splitting of districts:
- Merged districts are summed up under new identifier
- Split districts are distributed by population-based ratio.

Data on redistricting is in `data/` directory. Currently only available for German *Kreise* (containing reforms in NRW, Sachsen, Sachsen-Anhalt and Mecklenburg-Vorpommern).

Install like this:

    pip install pandas-redistrict


## Usage

``` python
>>> df  # Values indexed by German district identifiers
value1  value2
AGS
05354       4       5
05313       5       6
05334       6       7
15154       8       9
15159      10      11
15151      12      13
15082      13      14

>>> # Port old identifiers to new versions. Sum and distribute values on the way
>>> from redistrict import redistrict
>>> redistrict(df, 'de/kreise', drop=True, splits=True)
value1  value2
AGS
05334   15.00   18.00
15001    2.40    2.60
15082   35.44   38.81
15086    0.96    1.04
15091    4.20    4.55
```

When you want to preserve groups inside districts, you can use ``redistrict_grouped``:

``` python
>>> # Specify district column (e.g. AGS)
>>> # Also specify groups to preserve, in this case year
>>> df
     AGS  year  value1  value2
0  05354  2008       4       5
1  05313  2008       5       6
2  05334  2011       6       7
3  15154  2005       8       9
4  15159  2005      10      11
5  15151  2005      12      13
6  15082  2013      13      14
>>> from redistrict import redistrict_grouped
    redistrict_grouped(df, 'de/kreise', ['year'],
                                    district_col='AGS',
                                    value_cols=['value1', 'value2'],
                                    drop=True)

     AGS  value1  value2  year
0  15001    2.40    2.60  2005
1  15082   22.44   24.81  2005
2  15086    0.96    1.04  2005
3  15091    4.20    4.55  2005
0  05334    9.00   11.00  2008
0  05334    6.00    7.00  2011
0  15082   13.00   14.00  2013
```
processcall 1.1.0
a simple subprocess manager,suport stream stdout \ async
License: MIT
Keywords: subprocess processcall,fengyun

### 介绍

一个subprocess模块的封装,可以更方便的进行系统调用

To Do List:
....

[开发processcall的环境是python3哦]

### 安装

pip安装
```
pip install processcall
```

源码安装
```
git clone git@github.com:rfyiamcool/processcall.git
cd processcall
python setup.py install
```

### 使用方法

只单纯的执行，然后返回linux run code和执行状态

```
>>> import processcall
>>> r = processcall.run('uptime')
 04:06:37 up 2 min,  1 user,  load average: 0.20, 0.19, 0.08
>>> r.output
>>> r.success
True
>>> r.retcode
0
```

捕捉所有的执行结果
```
>>> r = processcall.run_capture('uptime')
>>> r.output
' 04:07:16 up 2 min,  1 user,  load average: 0.11, 0.17, 0.08\n'
>>> r.success
True
>>> r.retcode
0
```

把输出的结果精简过,maxlines是控制行数
```
print(run_capture_limited('ls', maxlines=2).output)
```

processcall example usage:

```
from processcall import run_capture

r = run_capture('ls -la')
if r.success:
    print(r.output)
else:
    print("Error: '%s' exit code %s" % (r.command, r.retcode))
    print("         ...")
    # print last three lines of output
    for line in r.output.splitlines()[-3:]:
        print("       %s" % line)
```