semvec/pypi-packages huggingface dataset:
ADPTC-LIB 0.0.7
自适应密度峰值树聚类（Adaptive Density Peak Tree Clustering）
Requires Python: >=3.6

<!--
 * @Description: 
 * @Author: SongJ
 * @Date: 2020-12-29 13:52:28
 * @LastEditTime: 2021-04-12 10:44:01
 * @LastEditors: SongJ
-->

## 自适应密度峰值树聚类（Adaptive Density Peak Tree Clustering）
本算法是在快速搜索与发现密度峰值聚类算法（Clustering by fast search and find of density peaks）CFSFDP的基础上进行改进的成果，主要解决的问题有:
- 手动选择聚类中心
- 单簇多密度峰值导致类簇误分
- 面向时空数据聚类时，无法顾及时空耦合
### 原理：
通过CFSFDP算法的核心概念：局部密度和斥群值，构建密度峰值树，通过直达点、连通点和切割点分离子树，达到类簇划分的目的。

<img src="https://cdn.jsdelivr.net/gh/SuilandCoder/PicStorage//img/image-20210409210616098.png" alt="image-20210409210616098" style="zoom: 80%;" />

![image-20210409210731545](https://cdn.jsdelivr.net/gh/SuilandCoder/PicStorage//img/image-20210409210731545.png)

![image-20210409212843640](https://cdn.jsdelivr.net/gh/SuilandCoder/PicStorage//img/image-20210409212843640.png)

### 使用方法：
#### 1. 安装:

```python
pip install ADPTC-LIB
```

#### 2. 空间数据聚类：

```python
import numpy as np
from ADPTC_LIB.cluster import ADPTC
from ADPTC_LIB import visual
X = np.loadtxt(r"../test_data/Aggregation.txt", delimiter="\t")
X = X[:,[0,1]]
atdpc_obj = ADPTC(X)
atdpc_obj.clustering(2)
visual.show_result(atdpc_obj.labels,X,np.array(list(atdpc_obj.core_points)))
```

![image-20210410095608378](https://cdn.jsdelivr.net/gh/SuilandCoder/PicStorage//img/image-20210410095608378.png)

#### 3. 空间属性数据聚类：

```python
from ADPTC_LIB.cluster import ADPTC
from ADPTC_LIB import visual
import xarray as xr
import os
import numpy as np
filePath = os.path.join(r'Z:\regions_daily_010deg\\05\\2013.nc')
dataset = xr.open_dataset(filePath)
pre_ds = dataset['precipitation']
lon = pre_ds.lon
lat = pre_ds.lat
lon_range = lon[(lon>-30)&(lon<70)]
lat_range = lat[(lat>30)&(lat<90)]
var = pre_ds.sel(lon=lon_range,lat = lat_range)
var = var.resample(time='1M',skipna=True).sum()
var_t = var.sel(time=var.time[0])
reduced = var_t.coarsen(lon=5).mean().coarsen(lat=5).mean()
data_nc = np.array(reduced)
spatial_eps=4
attr_eps=8
density_metric='gauss'
spre = ADPTC(data_nc)
spre.spacial_clustering_raster(spatial_eps,attr_eps,density_metric,knn_num=100,leaf_size=3000,connect_eps=0.9)
visual.show_result_2d(reduced,spre.labels)
```

![image-20210410104300578](https://cdn.jsdelivr.net/gh/SuilandCoder/PicStorage//img/image-20210410104300578.png)

#### 4.时空属性聚类：

```python
from ADPTC_LIB.cluster import ADPTC
from ADPTC_LIB import visual
import xarray as xr
import numpy as np
temp= xr.open_dataset(r'Z:\MSWX\temp\2020.nc')
temp_2020 = temp['air_temperature']
lon = temp_2020.lon
lat = temp_2020.lat
time = temp_2020.time
lon_range = lon[(lon>70)&(lon<140)]
lat_range = lat[(lat>15)&(lat<55)]
var = temp_2020.sel(lon=lon_range,lat = lat_range)
reduced = var.coarsen(lon=5).mean().coarsen(lat=5).mean()
data_nc = np.array(reduced)
s_eps = 5
t_eps = 1
attr_eps = 2.5
density_metric='gauss'
spre = ADPTC(data_nc)
spre.st_clustering_raster(s_eps,t_eps,attr_eps,density_metric,knn_num=100,leaf_size=3000,connect_eps=0.9)
visual.show_result_3d(reduced,spre,[70, 140, 15, 50],[0,12],21)
```

![image-20210412095947596](https://cdn.jsdelivr.net/gh/SuilandCoder/PicStorage//img/image-20210412095947596.png)
Understand 0.0.3
A package to detect intent from text based on training.
Requires Python: >=3.6

# Understand:
## Description:
Understand is a tool used to easily recognize intent based on training data. Visit the [site](https://ulto4.pythonanywhere.com) for more details

## Basic Usage:
```
from understand import Understand
model = Understand() #Initialize the model
model.fit() #Fits model based off training.json
model.predict('text') to predict text

```
abra 1.4.2
abra: open-source eye tracking data analysis

[![Build Status](https://travis-ci.org/abra-eyetracking/abra-eyetracking.svg?branch=master)](https://travis-ci.org/abra-eyetracking/abra-eyetracking)
## Abra Eye-tracking ver.1.3
Abra is an open-source python eye tracking data analysis tool which provides a simple interface for managing .edf files generated by EyeLink eye trackers.

#### Installation
Python 3:
`pip install abra`

Check out the documentation here: https://abra-eyetracking.github.io/
sqimple 0.1.1
Simple SQL Web Interface

# Sqimple

Simple SQL Web Interface for sqlite, mysql, and postgres databases.

Intended to be a step between the DBMS' interactive command line interface and a
fully-featured SQL GUI client.

![](demo.gif)

## Usage

```
python -m pip install sqimple
```

One of:

- sqlite

    ```
    sqimple sqlite mydb.sqlite
    ```

- mysql

    ```
    sqimple mysql -u someusername -p mypassword --host db.example.com some_database
    ```

- postgres

    ```
    sqimple pg -U username -d database
    ```

and then visit http://localhost:5000 in your browser.

See the help or subcommand help for more options:

```
sqimple --help
sqimple mysql --help
```

## Notes

- no state is persisted between query executions
- for postgres passwords, use a `~/.pgpass` file
- when saving the query to a file, if the specified filename already exists it
  will be overridden
- relies on `sqlite3`, `mysql`, or `psql` commands being installed
libtemplate 0.0.9.dev2
Template for python packages generated with cookiecutter-pylibrary
Requires Python: >=3.6

========
Overview
========



Template for python packages generated with cookiecutter-pylibrary

Installation
============

::

    pip install libtemplate

You can also install the in-development version with::

    pip install https://github.com/jpardovega/libtemplate/archive/master.zip


Documentation
=============


https://libtemplate.readthedocs.io/


Development
===========

To run all the tests run::

    tox

Note, to combine the coverage data from all the tox environments run:

.. list-table::
    :widths: 10 90
    :stub-columns: 1

    - - Windows
      - ::

            set PYTEST_ADDOPTS=--cov-append
            tox

    - - Other
      - ::

            PYTEST_ADDOPTS=--cov-append tox


Changelog
=========

0.0.1 (2021-04-08)
------------------

* Lots of new things

0.0.0 (2021-04-05)
------------------

* First release on PyPI.
dynamic-xml 1.1
An etree utility package

# dynamic-xml

A simple extension of Etree that gives users the ability to directly access attributes and nodes without having to
implement boilerplate python code.

Rationale for this library: [Dynamic XML Library with Python](https://claybrooks.github.io/python/2021/04/09/python-dynamic-xml.html)

`DynamicElement` is a drop-in replacement for any Etree code that you already have

```xml
<!-- ConfigFile.xml -->
<ConfigurationData>
    <Runtime timeout="1000" runtimeDataPath="/path/to/runtime/data" />
</ConfigurationData>
```

```python
# main.py
import dynamicxml

# parse the data and get back an instance of DynamicElement
root = dynamicxml.parse('data/ConfigFile.xml')

# Print the tag of the root element, just like you would a typical etree
# element
print (root.tag)

# get access to the runtime data node, which is a child of
# <ConfigurationData />.  The library returns a list of child
# nodes, regardless of how many elements there are.  An "AttributeError"
# is raised if the node does not exist.
runtimeNode = root.Runtime[0]

# Access the attributes of the node directly using the "attr_" prefix.
print (runtimeNode.attr_timeout)
print (runtimeNode.attr_runtimeDataPath)

# set the data directly
runtimeNode.attr_timeout = str(int(runtimeNode.attr_timeout) + 1)

# easy writing of the data
dynamicxml.write('data/ConfigFile_Updated.xml', root)

```
formula1 0.3.0
Python package that wraps Ergast F1 API
Requires Python: >=3.7

## F1PY
### Ergast API Python Wrapper


### Install
```
pip install f1py
```
---
### Usage

```python
from formula1 import F1

# no args
f1 = F1()

# http[s]
f1 = F1(secure=True)

# the api supports an offset and a limit
f1 = F1(secure=False, offset=20, limit=20)

# defaults to text/xml
f1.current_schedule().json
f1.all_drivers().json
f1.all_circuits().xml

# adding season to some endpoints
f1.season_schedule(season=2004).json
f1.race_standings(season=2020).json
f1.constructor_standings(season=2013).xml

# just the url
f1.driver_season(season=2020).url

# also supports random
f1.random(season=2020).json
```

```python
>> > from formula1 import F1
>> > f1 = F1(secure=True)
>> > f1_season = f1.driver_season(season=2002)
>> > print(f1_season.url)
>> > print(f1_season.json)
```


---
### Dev
```makefile
make deps
make test
```

---
### ToDo

- More Tests
- More Endpoints