semvec/pypi-packages huggingface dataset:
magicfiles 1.0.0
A simple powerfull module for files handling
Requires Python: >=3.6

# Magicfiles


`Magicfiles` is a powerfull python module to handle files using two main calsses:

- `FileObj` class to handle one file and allows you to make operations like:
1. read,write,size,readlines,strippedlines,remove
2. copy_to,move_to,write_json,read_json,renameto,...

---

- `FileGroup` class to handle a group of files and allow you to make:
* filter_by_size,filter_by_ext,read_all,write_all,remove_all
* filter_non_empty,filter_exists,total_size,...

---

- the module depends on the os, shutil, json modules... but it provides simplicity for handling files.


# Features

- Speed up file operations
- Simple human syntax
- Json Handling
- Continuous updates to the module

# FileObj

```python
file = FileObj("data.txt")
```

- We can do this methods :

`exist()` - Check if file exists

`get_parent_dir()` - Get file directory path

`get_extension()` - Get file extension

`is_empty()` - Check if file is empty

`content()` - Read file content

`write()` - Write data to file

`lines()` - Read lines

`stripped_lines()` - Read stripped lines

`create()` - Create the file if not exist

`move_to()` - Move file to another directory

`copy_to()` - Copy file to another directory

`read_json()` - Read json data -> dict

`write_json()` - Write json data

`renameto()` - Rename the file

`self_remove()` - Remove the file

`size()` - Get file size

`created_at()` - Return creation date

`modified_at()` - Return modification date


---

# FileGroup

```python
fg = FileGroup("file1.txt","file2.txt","file3.txt")
```

- We can do this methods :

`files()` - Return list of `FileObj` instances

`filter_non_empty()` - Return list of non empty files 

`filter_by_ext()` - Filter files by extension (Returns list)

`total_size()` - Return sum of files sizes in bytes

`filter_exists()` - Return list of exist files

`read_all()` - Read all files (Returns dict)

`write_all()` - Write to all files

`remove_all()` - Remove all files

`create_all()` - Create all files (if not exist)

`move_all_to()` - Move all files to directory

`filter_by_size()` - Filter files by size (min and max or equal)

- Example

```python
f1 = FileObj("data.txt")
f1.create()
f1.write("Hello World")
f1.rename("data_tmp.txt")
print(f1.size())
# you can use many functions .....
f1.remove()

fg = FileGroup("test1.txt","test2.txt","test3.txt")
fg.create_all()
fg.write_all("Hello World")

data: dict = fg.read_all()
print(data["test1.txt"]) # file1 content
# you can use many functions .....
fg.remove_all()
```
CytoOne 0.0.2
A unified probabilistic framework for CyTOF data
Requires Python: <3.11,>=3.9

![Logo](/assets/logo.png)

# CytoOne
> A unified probabilistic framework for CyTOF data

![Model Overview](/assets/model_overview.png)

## Installation 

You can easily install `CytoOne` from `PyPI`. Follow the following command to get started:

### Create a virtual environment :snake:

So far, we have only tested the software on Python 3.9 and 3.10.

```shell
conda create -n cytoone python=3.9
conda activate cytoone 
```

or 

```shell
conda create -n cytoone python=3.10
conda activate cytoone 
```

### Build the package

#### pip 

For a stable version of CytoOne, you can download and install the package via 

```shell
pip install CytoOne
```

#### Local 

The latest version of CytoOne will be hosted on GitHub where we constantly update features of the package. To use the latest version of CytoOne, you will need to build the package loacally.

First, you need to clone the repo to a local directory, say `./awesome_repos` and `cd` to that folder. 

Now, you should have a `CytoOne` folder under the `awesome_repos` directory. Run the following to build the package.

```shell 
cd ./CytoOne
python setup.py sdist bdist_wheel
```

You should see a `dist` folder now which contains the wheel file you will need for installing the package. 

```shell
cd ./dist
pip install ./CytoOne-0.0.1-py3-none-any.whl
```


### Dependencies 

With both package building strategies, the dependencies should be installed automatically. Here, we just list them out for your reference.  

- python>=3.9,<3.11
- numpy<2.0
- pandas>=2.2.0
- anndata>=0.10,<0.11
- torch<2.0
- pyro-ppl<1.8.5
- seaborn
- jupyter
- ipywidgets

## Tutorial :fast_forward:

### Interactive Python 
This assumes that you are using Jupyter notebook to run CytoOne.



### Command-Line Interface (CLI)




## Citation :page_with_curl:

If you use CytoOne in your workflow, citing [our paper](https://google.com) is appreciated:

```
@article{
}
```
terminal-ai-assistant 4.0.0
tAI, a terminal AI assistant

<h1 align="center">tAI, a terminal AI assistant</h1>

<div align="center">
tAI is a CLI that helps you with Linux and macOS terminal commands. Just ask it a question, and it will use AI to suggest a command and explain what it does. If you like the suggestion, the script can automatically run the command for you in your terminal.
</div>
<br />

![Demo](example.png)

## Why & What?

- Github Copilot CLI syntax feels clunky to me
- Faster than using Gemini, ChatGPT or similar in a browser
- Simpler to find answers without checking man pages
- **NEW:** Support for multiple AI providers (OpenAI, Google, Anthropic, Groq)
- **NEW:** Interactive TUI setup using `inquirer` for provider and model selection
- **NEW:** Enhanced terminal UI with `rich` for better readability and prompts
- **NEW:** Now you can run commands right from this command-line interface

However, never trust the output entirely.

## Installation

```bash
# install pipx (if you don't have it)
brew install pipx
pipx ensurepath

# install TAI
pipx install terminal-ai-assistant
```

## Usage

On your first run, `tai` will guide you through a quick, interactive setup process to choose your AI provider, select a model from a curated list, and enter your API key. This information will be securely stored in `~/.config/tai/config.json`.

Once configured, you can use `tai` with your queries:

```bash
$ tai kill port 3000

# Example output (formatted with rich):
╭────────────────────────────────────────────────── Command ───────────────────────────────────────────────────╮
│ kill $(lsof -t -i :3000)                                                                                     │
╰──────────────────────────────────────────────────────────────────────────────────────────────────────────────╯

Execute the command: kill $(lsof -t -i :3000)? [y/n]:
```

### Development

```bash
pip install --user pipenv
pipenv --python 3.11
pipenv install

pipenv run tai kill port 3000
```
pybmx 0.2.2
Bosch sensor BMP and BME library
Requires Python: >=3.10

# pybmx

This is a Python library for temperature, humidity and air pressure bosch sensor
devices like the BME280.

## Installation

```bash
python -m pip install pybmx
```

## Usage

```python
import time
import pybmx
import smbus2 as smbus

# Create a new BME280 object. The current sensor configuration is
# read from the sensor and can be printed.
bus = smbus.SMBus(1)
bme = pybmx.Bme280(bus)
bme.info()

# Configure the BME280 sensor. To enable all sensor functions, the
# oversampling must be activated.
bme.temperature_oversampling = pybmx.Bme280Oversampling.OVERSAMPLING_X1
bme.humidity_oversampling = pybmx.Bme280Oversampling.OVERSAMPLING_X1
bme.pressure_oversampling = pybmx.Bme280Oversampling.OVERSAMPLING_X1
bme.duration = pybmx.Bme280Duration.DURATION_10

# After the configuration, the sensor must be updated to apply the
# new settings.
bme.update()
bme.info()

try:
    while True:
        # You can read the sensor data with the measure() method. The
        # data contains the temperature, humidity and pressure values.
        datapoint = bme.measure()
        print("-" * 20)
        print(f"timestamp: {datapoint.timestamp}")
        print(f"temperature: {datapoint.temperature:.3f} °C")
        print(f"humidity: {datapoint.humidity:.3f} %rH")
        print(f"pressure: {datapoint.pressure:.3f} hPa")

        time.sleep(5.0)
except KeyboardInterrupt:
    pass
finally:
    bus.close()
```
carlson-leaf-area-index 1.1.0
Leaf Area Index (LAI) Remote Sensing Method from Carlson et al 1997 Python Package
Requires Python: >=3.10

# carlson-leaf-area-index

Leaf Area Index (LAI) Remote Sensing Method from Carlson et al 1997 Python Package

Gregory H. Halverson (they/them)<br>
[gregory.h.halverson@jpl.nasa.gov](mailto:gregory.h.halverson@jpl.nasa.gov)<br>
NASA Jet Propulsion Laboratory 329G
  

## Overview

This package provides a Python implementation of the Leaf Area Index (LAI) algorithm described by Carlson & Ripley (1997) and related literature. It converts NDVI (Normalized Difference Vegetation Index) data to LAI using a two-step process based on canopy light absorption and the Beer-Lambert law, suitable for remote sensing applications.

## Features

- Converts NDVI to Leaf Area Index (LAI)
- Supports both NumPy arrays and `rasters.Raster` objects
- Based on peer-reviewed scientific literature

## Installation

Install via pip:

```fish
pip install carlson-leaf-area-index
```

## Usage


```python
import numpy as np
from carlson_leaf_area_index import carlson_leaf_area_index

# Example NDVI array
NDVI = np.array([[0.1, 0.3, 0.5], [0.04, 0.52, 0.25]])
LAI = carlson_leaf_area_index(NDVI)
print(LAI)
```


## Algorithm

The algorithm converts NDVI to LAI in two main steps:

1. **Estimate fIPAR (fraction of absorbed photosynthetically active radiation) from NDVI:**
	- `fIPAR = clip(NDVI - 0.05, min_fIPAR, max_fIPAR)`
	- This relates NDVI to the fraction of light absorbed by the canopy.

2. **Calculate LAI using the Beer-Lambert law:**
	- `LAI = -ln(1 - fIPAR) / KPAR`
	- KPAR is the extinction coefficient for PAR (default 0.5).

3. **Clipping:**
	- Results are clipped to a valid LAI range (default 0–10).

Values of fIPAR below the minimum are set to NaN (no absorption), and LAI is clipped to the specified range.

## References


- Carlson, T.N., & Ripley, D.A. (1997). On the relation between NDVI, fractional vegetation cover, and leaf area index. Remote Sensing of Environment, 62(3), 241-252. [https://doi.org/10.1016/S0034-4257(97)00104-1](https://doi.org/10.1016/S0034-4257(97)00104-1)
- Monsi, M., & Saeki, T. (1953). Über den Lichtfaktor in den Pflanzengesellschaften und seine Bedeutung für die Stoffproduktion. Japanese Journal of Botany, 14, 22-52.
- Goudriaan, J. (1977). Crop Micrometeorology: A Simulation Study.

## License

See LICENSE file for details.
Collect-withCamera 0.1.0
A camera live module to collect data for image predictions.
Requires Python: >=3.6

# <center>🎥Image Data Collection</center>

## Instructions For Detection Data.

***

* To create a bounding box around an object, press and hold **Ctrl** while simultaneously pressing the **left mouse button**. Drag the cursor to encompass the desired object within the box.

* To assign a name to the object, **right-click** within the bounding box. Alternatively, repeat the bounding box creation process as described above.

* Enter the object's name in the console and press **Enter** to confirm.

* Multiple objects can be labeled sequentially by repeating the aforementioned steps for each object.

* Initiate the timer by pressing and holding **Ctrl** while **right-clicking**.

* Please note that once image capture has commenced, redrawing bounding boxes is disabled until the capture process is complete.
* To terminate the process, press the Esc key.

### init code
***
~~~
from CollectwithCamera import detectionDataCollection
if __name__ == __main__:
  dtest = detectionDataCollection()
  dtest.set_sourceID(0)
  dtest.set_nSamples(1)
  dtest.set_Timer(5)
  dtest.camera_init_()
  dtest.annotation()
~~~

## Instructions for Classification Data
***
*   To designate an object, **left-click** and drag the cursor to create a bounding box encompassing the desired item.
*   **Right-click** within the bounding box to input the object's name.
*   Upon pressing **Enter**, the data acquisition timer will commence.
*   Data capture will proceed for the specified number of samples.
*   To terminate the process, press the **Esc** key.

### init code
***
~~~
from CollectwithCamera import classificationDataCollection
if __name__ == __main__:
  test = classificationDataCollection()
  test.set_SourceID(0)
  test.set_semples(1)
  test.set_timer(5)
  test.camera_init_()
  test.imageCropingAndCapturing()
~~~
***
# <center> To be continued ....</center>

***