Skip to main content
SpectrumLab

A pioneering unified platform designed to systematize and accelerate deep learning research in spectroscopy.

🚀 Quick Start

Environment Setup

We recommend using conda and uv for environment management:

# Clone the repository
git clone https://github.com/little1d/SpectrumLab.git
cd SpectrumLab

# Create conda environment
conda create -n spectrumlab python=3.10
conda activate spectrumlab

pip install uv
uv pip install -e .

Data Setup

Download benchmark data from Hugging Face:

Extract the data to the data directory in the project root.

API Keys Configuration

# Copy and edit environment configuration
cp .env.example .env
# Configure your API keys in the .env file

💻 Usage

Python API

from spectrumlab.benchmark import get_benchmark_group
from spectrumlab.models import GPT4o
from spectrumlab.evaluator import get_evaluator

# Load benchmark data
benchmark = get_benchmark_group("perception")
data = benchmark.get_data_by_subcategories("all")

# Initialize model
model = GPT4o()

# Get evaluator
evaluator = get_evaluator("perception")

# Run evaluation
results = evaluator.evaluate(
    data_items=data,
    model=model,
    save_path="./results"
)

print(f"Overall accuracy: {results['metrics']['overall']['accuracy']:.2f}%")

Command Line Interface

The CLI provides a simple way to run evaluations:

# Basic evaluation
spectrumlab eval --model gpt4o --level perception

# Specify data path and output directory
spectrumlab eval --model claude --level signal --data-path ./data --output ./my_results

# Evaluate specific subcategories
spectrumlab eval --model deepseek --level semantic --subcategories "IR_spectroscopy" "Raman_spectroscopy"

# Customize output length
spectrumlab eval --model internvl --level generation --max-length 1024

# Get help
spectrumlab eval --help

🤝 Contributing

We welcome community contributions! Please see CONTRIBUTING.md for detailed guidelines.

Acknowledgments

  • Experiment Tracking: SwanLab for experiment management and visualization
  • Choice Evaluator Framework: Inspired by MMAR

Metadata

Release files for spectrumlab 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for spectrumlab 0.1.2
File Size Uploaded Provenance Actions
spectrumlab-0.1.2.tar.gz 691.8 kB Without provenance Details for spectrumlab-0.1.2.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for spectrumlab 0.1.2
File Interpreter ABI Platform Actions
spectrumlab-0.1.2-py3-none-any.whl Python 3 none any Details for spectrumlab-0.1.2-py3-none-any.whl

Total release size: 726.2 kB

Release files / spectrumlab-0.1.2.tar.gz

Download URL spectrumlab-0.1.2.tar.gz
Size 691.8 kB
Tags Source
SHA-256 checksum
How to use checksums
5b44037f1b3409467fb42589ce2e167b004e5dfc541cbba23b5c4faae27f7a4f
BLAKE2b-256 checksum
How to use checksums
c54c1be28b50900a8f876767b03022693dd18fb3aa3ff415edb5681647ad2523
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.8.5

Release files / spectrumlab-0.1.2-py3-none-any.whl

Download URL spectrumlab-0.1.2-py3-none-any.whl
Size 34.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c95aa227a8923bcef4c62248c86f56485971fc8c2edf6e0922946d458b7c3f8b
BLAKE2b-256 checksum
How to use checksums
84b57e0c82765892c5d5ad0c3e25eaaea43ddc326f439dba40e24fa4e114dce6
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.8.5

Security for spectrumlab 0.1.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page