semvec/pypi-packages huggingface dataset:
zdppy-mysql 0.1.5
Python连接MySQL的底层核心库
Requires Python: <4.0,>=3.8

# zdppy_mysql

使用python操作MySQL

项目开源地址：https://github.com/zhangdapeng520/zdppy_mysql

## 安装

```bash
pip install zdppy_mysql
```

## 使用教程

### 连接MySQL

```python
import zdppy_mysql
from config import host, username, password, database, port

# 连接数据库
db = zdppy_mysql.connect(
    host,
    username,
    password,
    database,
    port,
)
print(db)
```

### 添加数据库

```python
import zdppy_mysql
from config import host, username, password, database, port

# 连接数据库
db = zdppy_mysql.connect(
    host,
    username,
    password,
    database,
    port,
)

# 使用游标对象执行SQL语句
with db.cursor() as cur:
    # 创建数据库
    sql = "create database if not exists test"
    cur.execute(sql)

    # 查询所有数据库
    sql = "show databases"
    cur.execute(sql)
    print(cur.fetchall())
```

### 查询所有表

```python
import zdppy_mysql
from config import host, username, password, database, port

# 连接数据库
db = zdppy_mysql.connect(
    host,
    username,
    password,
    database,
    port,
    cursorclass=zdppy_mysql.cursors.DictCursor,
)

# 使用游标对象执行SQL语句
with db.cursor() as cur:
    # 查询所有数据库
    sql = "show tables"
    cur.execute(sql)
    print(cur.fetchall())
```

### 添加表

```python
import zdppy_mysql
from config import host, username, password, database, port

# 连接数据库
db = zdppy_mysql.connect(
    host,
    username,
    password,
    database,
    port,
    cursorclass=zdppy_mysql.cursors.DictCursor,
)

# 使用游标对象执行SQL语句
with db.cursor() as cur:
    # 查询所有数据库
    sql = "create table user(id int primary key auto_increment, name varchar(255))"
    cur.execute(sql)
    db.commit()
```

### 添加数据

```python
import zdppy_mysql
from config import host, username, password, database, port

# 连接数据库
db = zdppy_mysql.connect(
    host,
    username,
    password,
    database,
    port,
    cursorclass=zdppy_mysql.cursors.DictCursor,
)

# 使用游标对象执行SQL语句
with db.cursor() as cur:
    cur.execute("insert into user(name) values(%s)", ("张三1",))
    cur.execute("insert into user(name) values(%s)", ("张三2",))
    cur.execute("insert into user(name) values(%s)", ("张三3",))

    # 必须加commit才会提交到数据库保存
    db.commit()
```

### 查询所有数据

```python
import zdppy_mysql
from config import host, username, password, database, port

# 连接数据库
db = zdppy_mysql.connect(
    host,
    username,
    password,
    database,
    port,
    cursorclass=zdppy_mysql.cursors.DictCursor,
)

# 使用游标对象执行SQL语句
with db.cursor() as cur:
    # 查询所有数据库
    cur.execute("select * from user")
    print(cur.fetchall())
```

## 版本历史

- 0.1.1 解决mysql8初次连接报auth异常的问题
- 0.1.4 移除Database类及其他语法糖，全部移交mcrud处理

### v0.1.5

- 架构优化

## 注意事项

如果报权限异常错误，请手动执行依赖：

```bash
pip install cryptography
```
matplotlive 1.1.1
Stream live plots to a matplotlib figure.
Requires Python: >=3.8

# matplotlive

[![Build](https://img.shields.io/github/actions/workflow/status/stephane-caron/matplotlive/ci.yml?branch=main)](https://github.com/stephane-caron/matplotlive/actions)
[![Documentation](https://img.shields.io/github/actions/workflow/status/stephane-caron/matplotlive/docs.yml?branch=main&label=docs)](https://stephane-caron.github.io/matplotlive/)
[![Coverage](https://coveralls.io/repos/github/stephane-caron/matplotlive/badge.svg?branch=main)](https://coveralls.io/github/stephane-caron/matplotlive?branch=main)
[![Conda version](https://img.shields.io/conda/vn/conda-forge/matplotlive.svg)](https://anaconda.org/conda-forge/matplotlive)
[![PyPI version](https://img.shields.io/pypi/v/matplotlive)](https://pypi.org/project/matplotlive/)

Stream live plots to a [Matplotlib](https://matplotlib.org/) figure.

## Example

```py
import math
import matplotlive

plot = matplotlive.LivePlot(
    timestep=0.01,  # seconds
    duration=1.0,   # seconds
    ylim=(-5.0, 5.0),
)

for i in range(10_000):
    plot.send("bar", math.sin(0.3 * i))
    plot.send("foo", 3 * math.cos(0.2 * i))
    plot.update()
```

## Installation

### From conda-forge

```console
conda install -c conda-forge matplotlive
```

### From PyPI

```console
pip install matplotlive
```

## See also

- [Teleplot](https://github.com/nesnes/teleplot): alternative to plot telemetry data from a running program.
pyhtmlify 0.1.8
HTML in Pure Python
Requires Python: >=3.6

# pyhtmlify

<p align="center">
<a href="https://pepy.tech/project/pyhtmlify"><img alt="Downloads" src="https://static.pepy.tech/badge/pyhtmlify">
<a style="text-decoration:none" href="https://github.com/Peggun/pyhtmlify/action/workflows/ci.yml">
    <img src="https://img.shields.io/github/actions/workflow/status/Peggun/pyhtmlify/ci.yml?label=pyhtmlify%20CI" alt="pyhtmlify CI" /></a>

pyhtmlify is a Python package that allows you to write HTML code with Pure Python. This package was mainly made for the [osd Project](https://github.com/Peggun/osd) for simplicity. Heres how to use it. This package isn't completely finished, as we are still adding heaps of stuff and more HTML tags to this project.

Just quickly as well, currently you are unable to use the doctype and html tags as they are bugged and I do not know why. If you would like to add these tags, do so manually in the html file. If you would like to help fix this bug, please feel free too.

## 1. Installation
You can install pyhtml using pip
```py
pip install pyhtmlify
```
This will install the latest version of pyhtmlify.

## 2. How to use
pyhtmlify is quite easy to use. It is similar to html, but without all of the <> and other things involved. To do so, make a python file starting with html- and pyhtmlify will pick it up.

For pyhtmlify to pick up the file to generate the html code for you, you need to have a index function inside of your script. Like this for example:
```py
import pyhtmlify.HTMLTags.tags as ph

def index():
    return ph.div(
        ph.h1("Welcome to My Website"),
        ph.input(type="text", placeholder="Enter your name"),
    )
```

That is all you need for the script side. Now onto the html conversion

## 3. PY to HTML Conversion
To convert python index functions into html documents, pyhtmlify comes with a pyhtmlify command to use. In the terminal, to generate html code for all the html-*.py files, run 
```py
pyhtmlify generate -f folder -i input_file -n file_name
```
The -f flag specifies the output folder, and there are some other flags and commands that are coming up. 
However, you you dont use the -f flag, the program automatically defaults to /html.

The -i flag specifies the file you would like to generate html for. This defaults to the whole directory

The -n flag specifies the output files name. This defaults to the same name as the py file.

There is also a find command
```py
pyhtmlify find -f folder
```
This command finds all possible files to generate and tell you the file and the file path to it. If the -f flag isnt used, it will scan the entire working directory.

## 4. Contribution
If you would like to contribute to this project, please check out the issues and contact me at peggundev@gmail.com, or come check out osd and join the discord community!
pyxl30-tspspi 0.0.13
Control libraries and utilities for the XL30 ESEM (unofficial)
Requires Python: >=3.6

# Philips XL30 Environmental Scanning Electron Microscope (ESEM) control libraries and utilities (unofficial)

_Under development_

This repository contains a small set of utilities and control libraries for
the Philips XL30 environmental scanning electron microscope (ESEM). __This
code is not associated with Philips or FEI in any way__.

Current available components:

* The ```xl30serial.xl30serial``` module provides a simple interface
  to the XL30 using it's serial console server. Remote control via the
  serial interface has to be enabled on the console. This route of control
  has been chosen since DDE and shared memory via flat thunking is not
  working since the Windows 2K update. Unfortunately not all parameters
  like chamber pressure are available via the serial port - and transfer
  of images has to work via files. __This library is under development
  and may change at any point in future__. It only implements a small
  subset of the supported commands.

## Installation

This package is available as PyPi package and automatically build on each
tag by an automated build system.

```
pip install pyxl30-tspspi
```

## Usage

### Simple sample with internal methods

This simple sample currently uses private methods of the class. Usually
one should access the microscope via it's base class from
the [pylabdevs](https://github.com/tspspi/pylabdevs/tree/master) project.
This base class is currently under development.

```
from xl30serial import XL30Serial
from time import sleep

with XL30Serial("/dev/ttyU0", logger, debug = True) as xl:
   print(xl._get_id())
   xl._set_hightension(30e3)
   sleep(120)
   xl._set_scanmode(ScanningElectronMicroscope_ScanMode.FULL_FRAME)
   xl._set_imagefilter_mode(ScanningElectronMicroscope_ImageFilterMode.INTEGRATE, 1)
   while(xl._get_imagefilter_mode()['mode'] != ScanningElectronMicroscope_ImageFilterMode.FREEZE):
      sleep(0.5)
   xl._write_tiff_image("c:\\temp\\IMAGE.TIF")

   xl._set_scanmode(ScanningElectronMicroscope_ScanMode.FULL_FRAME)
   xl._set_hightension(0)

```