Metadata-Version: 2.1
Name: colliderml
Version: 0.1.3
Summary: A modern machine learning library for high-energy physics data analysis
Home-page: https://github.com/murnanedaniel/colliderml
Author: Daniel Murnane
Author-email: dtmurnane@lbl.gov
License: UNKNOWN
Project-URL: Documentation, https://murnanedaniel.github.io/colliderml
Project-URL: Source, https://github.com/murnanedaniel/colliderml
Project-URL: Issues, https://github.com/murnanedaniel/colliderml/issues
Platform: UNKNOWN
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Topic :: Scientific/Engineering :: Physics
Requires-Python: >=3.10,<3.12
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: requests (>=2.31.0)
Requires-Dist: tqdm (>=4.66.0)
Requires-Dist: numpy (>=1.24.0)
Requires-Dist: pydantic (>=2.5.0)
Requires-Dist: h5py (>=3.10.0)
Provides-Extra: dev
Requires-Dist: pytest (>=7.4.0) ; extra == 'dev'
Requires-Dist: pytest-cov (>=4.1.0) ; extra == 'dev'
Requires-Dist: black (>=23.11.0) ; extra == 'dev'
Requires-Dist: ruff (>=0.1.6) ; extra == 'dev'
Requires-Dist: mypy (>=1.7.0) ; extra == 'dev'
Requires-Dist: mkdocs-material (>=9.4.0) ; extra == 'dev'
Requires-Dist: mkdocstrings[python] (>=0.24.0) ; extra == 'dev'

# ColliderML

[![Tests](https://github.com/murnanedaniel/colliderml/actions/workflows/tests.yml/badge.svg)](https://github.com/murnanedaniel/colliderml/actions/workflows/tests.yml)
![Coverage](./coverage.svg)
[![Python 3.10+](https://img.shields.io/badge/python-3.10%2B-blue.svg)](https://www.python.org/downloads/)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)

A modern machine learning library for high-energy physics data analysis.

## Features

- Efficient parallel data downloading with resume capability
- Support for common HEP data formats
- Machine learning utilities for particle physics
- Visualization tools for physics data

## Installation

### For Users
```bash
# Create and activate environment
conda create -n collider-env python=3.11  # 3.10 or 3.11 recommended
conda activate collider-env

# Install package
pip install colliderml
```

### For Developers
```bash
# Create and activate environment
conda create -n collider-dev python=3.11  # 3.10 or 3.11 recommended
conda activate collider-dev

# Clone repository
git clone https://github.com/murnanedaniel/colliderml.git
cd colliderml

# Install in development mode with extra dependencies
pip install -e ".[dev]"
```

## Quick Start

### CLI

```bash
# Download 100 events from the taster campaign into ./data
colliderml get -c taster -e 100 -O data
```

```python
from colliderml.core.data.manifest import ManifestClient
from colliderml.core.io import DataDownloader

manifest = ManifestClient()
files = manifest.select_files(campaign=None, datasets=["ttbar"], objects=["tracks"], max_events=1000)

downloader = DataDownloader()
results = downloader.download_files([f.path for f in files], local_dir="data", max_workers=4, resume=True)

for path, result in results.items():
    print(path, result.success, result.error)
```

### Features

- **Manifest-driven**: Always selects files from the latest portal manifest
- **Parallel Downloads**: Download multiple files concurrently
- **Resume Capability**: Optionally resume interrupted downloads
- **Progress Tracking**: Real-time progress bars
- **Clear Errors**: Helpful failure messages and HEAD checks

## Development

1. Activate your environment:
   ```bash
   conda activate collider-dev
   ```

2. Run tests:
   ```bash
   # Run unit tests only
   pytest -v -m "not integration"
   
   # Run all tests including integration tests
   pytest -v
   
   # Run with coverage report
   pytest --cov=colliderml
   ```

3. Build documentation:
   ```bash
   mkdocs build
   mkdocs serve  # View at http://127.0.0.1:8000
   ```

## License

[MIT License](LICENSE) 

