semvec/pypi-packages huggingface dataset:
agroecometrics 0.1.1
Agricultural ecology metrics and visualization tools.
Requires Python: >=3.7

# AgroEcoMetrics

AgroEcoMetrics is a useful tool for manipulating agricultural and Ecological data

Source code:    ([https://github.com/wiscbicklab/AgroEcoMetrics](https://github.com/wiscbicklab/AgroEcoMetrics))

Bug reports:    ([https://github.com/wiscbicklab/AgroEcoMetrics/issues](https://github.com/wiscbicklab/AgroEcoMetrics/issues))

Documentation:  ([https://wiscbicklab.github.io/AgroEcoMetrics/](https://wiscbicklab.github.io/AgroEcoMetrics/))

It provides:

- Methods for calulating agricultural and ecological data
- Methods for manipulating and cleaning agriculture and ecological data
- Methods for visualizing agricultural and ecological data

## Submodules Overview

### `agroecometrics.data`

Provides utilities for loading, cleaning, interpolating, manipulating, and saving agricultural datasets. Includes functions to:

- Check CSV file validity
- Load and filter data by date range
- Interpolate missing data
- Save processed DataFrames
- Match date times between numpy arrays
- Get a pandas DataFrame as a dictionary

### `agroecometrics.equations`

Contains models and equations for ecological and agricultural analysis, including:

- **TEMPERATURE MODELS**: Soil and Air Temperature Prediction Models.
- **Evapotranspiration Models**: Dalton, Penman, Hargreaves, etc.
- **Crop Models**: Calculate Growing Degree Days (GDD)
- **Photoperiod Models**: Photoperiod Predictions.
- **Water Movement Models**: Infiltration and hydraulic conductivity

### `agroecometrics.visualizations`

Provides methods for creating plots from the calulations made in equations.

- Air Temperature plots
- Soil temperature plots and 3d mesh graphs
- Rainfall and runoff plot
- Growing degree day plots
- Photoperiod prediction plots

## Getting Started

### Installation

Install via pip:

```bash
pip install AgroEcoMetrics
```

### Quick Example

```python
from pathlib import Path
from agroecometrics as AEM
import pandas as pd

# Load your data
data_path = Path("**your_weather_data.csv**")
image_path = Path("**your_saved_plot.png**")
df = AEM.data.load_data_csv(data_path, "**date_time_col_name**", start_date='2024-01-01', end_date='2024-12-31')

# Create a Graph of air temperature on a particular day
date_times = df["**date_time_col_name**"]
avg_air_temp = df['**avg_air_temp_col_name**']
air_temp_pred = AEM.equations.model_air_temp(avg_air_temp)
AEM.visualizations.plot_air_temp(avg_air_temp, air_temp_pred, date_times, image_path)
```

This script loads weather data filtered to only 2024, creates an air temperature models from the data, and saves a plot of the predicted temperatures from the model against the actual temperatures.
chty 0.1.2
Type-safe ClickHouse query parameter codegen from SQL files
Requires Python: >=3.10

# chty

End-to-end type-safe ClickHouse query codegen from SQL files.

[![Documentation](https://img.shields.io/badge/docs-mkdocs-blue)](https://treygilliland.github.io/chty/)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)

## Installation

```bash
# Run directly without installation
uvx chty

# Or install globally
uv tool install chty

# Or use pip/pipx
pip install chty
```

## Quick Start

Create a `.sql` file with ClickHouse parameterized queries:

```sql
-- queries/example.sql
SELECT number, number * {multiplier:Int32} AS result
FROM system.numbers
WHERE number < {limit:Int32}
```

Generate typed Python code:

```bash
# Local ClickHouse
chty generate queries/ --output generated/ --db-url clickhouse://user:pass@host:port

# ClickHouse Cloud
chty generate queries/ --output generated/ --db-url https://user:pass@host.clickhouse.cloud:8443
```

Use the generated code:

```python
from generated.example import ExampleParams, ExampleQuery
import clickhouse_connect

client = clickhouse_connect.get_client(host="localhost")
params = ExampleParams(multiplier=3, limit=5)
query = ExampleQuery(client)

results = query.execute(params)
for row in results:
    print(f"Number: {row['number']}, Result: {row['result']}")
```

Validate generated code against your database schema:

```bash
# Detect schema drift in CI/CD or before deployment
chty validate generated/ --db-url clickhouse://user:pass@host:port

# Returns exit code 0 if valid, 1 if schema has changed
```

## Features

- ✅ **Type-safe parameters** - Catch parameter errors at development time
- ✅ **Type-safe results** - Full autocomplete for result fields (with `--db-url`)
- ✅ **Schema validation** - Detect schema drift with `chty validate`
- ✅ **Multiple execution methods** - `execute()` and `execute_df()` for DataFrames
- ✅ **Optional runtime validation** - Validate result schema at runtime
- ✅ **Zero runtime overhead** - TypedDict is just type annotations

## Why chty?

ClickHouse queries in Python lack type safety. `chty` connects your SQL queries directly to Python's type system:

**Without chty:**

- ❌ No autocomplete for query parameters or results
- ❌ Errors only caught at runtime
- ❌ No way to detect schema drift

**With chty:**

- ✅ Full type safety from SQL to Python
- ✅ IDE autocomplete everywhere
- ✅ Catch errors at development time
- ✅ Detect schema changes in CI/CD

## Documentation

Full documentation is available at [https://treygilliland.github.io/chty/](https://treygilliland.github.io/chty/)

## Development

Common development tasks are available via `make`. See Makefile for more.

## Contributing

Contributions are welcome! Please see [CONTRIBUTING.md](CONTRIBUTING.md) for details.

## License

MIT License - see [LICENSE](LICENSE) for details.
pyvxlapi 0.1.2
Python Wrapper for Vector XL Driver Library
Requires Python: >=3.9

# pyvxlapi

Python Wrapper for Vector XL Driver Library

The `pyvxlapi.py` is convert from `vxlapi.h` by [ctypesgen](https://github.com/ctypesgen/ctypesgen)

## Installation
```
$ uv venv
$ uv pip install pyvxlapi
```

## Development
```sh
$ uv sync
$ uv run ctypesgen -lvxlapi64 --strip-build-path="C:\\pyvxlapi\\assets\\" -o src/pyvxlapi/__init__.py assets/vxlapi.h
```

## Example

```py
from pyvxlapi import (
    XLdriverConfig,
    xlGetDriverConfig,
)

driver_config = XLdriverConfig()
status = xlGetDriverConfig(driver_config)
print(status)

for i in range(driver_config.channelCount):
    channel_config = driver_config.channel[i]
    print(f"{i} {channel_config.name} {channel_config.channelMask}")
```