hpfracc


Namehpfracc JSON
Version 1.1.2 PyPI version JSON
download
home_pageNone
SummaryHigh-Performance Fractional Calculus Library with Machine Learning Integration and Graph Neural Networks
upload_time2025-08-25 04:30:59
maintainerNone
docs_urlNone
authorNone
requires_python>=3.8
licenseNone
keywords fractional-calculus numerical-methods machine-learning graph-neural-networks jax pytorch numba scientific-computing mathematics deep-learning
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # HPFRACC - High-Performance Fractional Calculus Library

[![PyPI version](https://badge.fury.io/py/hpfracc.svg)](https://badge.fury.io/py/hpfracc)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
[![Python 3.8+](https://img.shields.io/badge/python-3.8+-blue.svg)](https://www.python.org/downloads/)
[![Documentation](https://img.shields.io/badge/docs-latest-brightgreen.svg)](https://hpfracc.readthedocs.io/)

## πŸ‘¨β€πŸ’» **Author & Developer**

**Davian R. Chin**  
Department of Biomedical Engineering  
University of Reading  
Email: [d.r.chin@pgr.reading.ac.uk](mailto:d.r.chin@pgr.reading.ac.uk)  
GitHub: [@dave2k77](https://github.com/dave2k77)

## πŸš€ **Overview**

HPFRACC (High-Performance Fractional Calculus Library) is a comprehensive Python library that provides high-performance implementations of fractional calculus operations, advanced numerical methods, and machine learning integration with fractional derivatives.

## ✨ **Key Features**

### πŸ”¬ **Core Fractional Calculus**
- **Multiple Definitions**: Riemann-Liouville, Caputo, GrΓΌnwald-Letnikov, and more
- **High-Performance Algorithms**: Optimized implementations for speed and accuracy
- **GPU Acceleration**: CUDA support for large-scale computations
- **Advanced Methods**: Mellin transforms, fractional differential equations, and special functions

### πŸ€– **Machine Learning Integration**
- **Multi-Backend Support**: Seamless integration with PyTorch, JAX, and NUMBA
- **Fractional Neural Networks**: Core networks with fractional calculus integration
- **Fractional Attention Mechanisms**: Multi-head attention with fractional derivatives
- **Graph Neural Networks**: Fractional GNN architectures for graph learning tasks
- **Comprehensive ML Components**: Loss functions, optimizers, and layers (in development)

### 🎯 **Performance & Usability**
- **Cross-Platform**: Windows, macOS, and Linux support
- **Extensive Documentation**: Comprehensive guides and examples
- **Active Development**: Regular updates and improvements
- **Research-Ready**: Designed for academic and industrial applications

## πŸ—οΈ **Architecture**

### **Multi-Backend Support**
HPFRACC provides a unified interface across multiple computation backends:

- **PyTorch**: Full-featured deep learning with GPU acceleration
- **JAX**: High-performance numerical computing with automatic differentiation
- **NUMBA**: JIT compilation for CPU optimization

### **Core Components**
- **Backend Management**: Automatic detection and seamless switching between backends
- **Unified Tensor Operations**: Consistent API across all backends
- **Fractional Calculus Integration**: Built-in fractional derivatives in all ML components

## πŸ“¦ **Installation**

### **Basic Installation**
```bash
pip install hpfracc
```

### **Full Installation with ML Dependencies**
```bash
pip install hpfracc[ml]
```

### **Development Installation**
```bash
git clone https://github.com/dave2k77/hpfracc.git
cd hpfracc
pip install -e .
```

## πŸš€ **Quick Start**

### **Basic Fractional Calculus**
```python
from hpfracc import FractionalOrder, riemann_liouville

# Create fractional order
alpha = FractionalOrder(0.5)

# Compute fractional derivative
result = riemann_liouville(function, t, alpha)
```

### **Multi-Backend Neural Networks**
```python
from hpfracc.ml import BackendType, FractionalNeuralNetwork
from hpfracc.core.definitions import FractionalOrder

# Create network with JAX backend
network = FractionalNeuralNetwork(
    input_size=10,
    hidden_sizes=[32, 16],
    output_size=2,
    fractional_order=FractionalOrder(0.5),
    backend=BackendType.JAX
)

# Forward pass with fractional derivatives
output = network(input_data, use_fractional=True, method="RL")
```

### **Fractional Attention Mechanism**
```python
from hpfracc.ml import FractionalAttention

# Create attention with fractional calculus
attention = FractionalAttention(
    d_model=64,
    n_heads=8,
    fractional_order=FractionalOrder(0.5),
    backend=BackendType.TORCH
)

# Apply fractional attention
output = attention(input_sequence, method="RL")
```

### **Fractional Graph Neural Networks**
```python
from hpfracc.ml import FractionalGNNFactory, BackendType
from hpfracc.core.definitions import FractionalOrder

# Create GNN with fractional calculus
gnn = FractionalGNNFactory.create_model(
    model_type='gcn',  # Options: 'gcn', 'gat', 'sage', 'unet'
    input_dim=16,
    hidden_dim=32,
    output_dim=4,
    fractional_order=FractionalOrder(0.5),
    backend=BackendType.JAX
)

# Forward pass on graph data
output = gnn(node_features, edge_index)
```

## πŸ”§ **Current Status**

### **βœ… Fully Working**
- **Core Fractional Calculus**: All mathematical operations and algorithms
- **Backend Management**: Seamless switching between PyTorch, JAX, and NUMBA
- **Core Neural Networks**: FractionalNeuralNetwork with multi-backend support
- **Attention Mechanisms**: FractionalAttention with fractional derivatives
- **Tensor Operations**: Unified API across all backends
- **Graph Neural Networks**: Complete GNN architectures (GCN, GAT, GraphSAGE, U-Net)

### **🚧 In Development**
- **Advanced Layers**: Conv1D, Conv2D, LSTM, Transformer layers
- **Loss Functions**: Comprehensive loss function library
- **Optimizers**: Fractional gradient-based optimizers

### **πŸ“‹ Planned Features**
- **Advanced ML Components**: Complete layer and optimizer library
- **Performance Optimization**: Backend-specific optimizations
- **Research Tools**: Benchmarking and analysis utilities
- **Extended GNN Support**: Additional graph neural network architectures and graph types

## πŸ“š **Documentation**

- **User Guide**: [docs/user_guide.md](docs/user_guide.md)
- **API Reference**: [docs/api_reference.md](docs/api_reference.md)
- **Examples**: [examples/](examples/) directory
- **Development Guide**: [README_DEV.md](README_DEV.md)

## 🀝 **Contributing**

We welcome contributions! Please see our [Contributing Guidelines](CONTRIBUTING.md) and [Development Guide](README_DEV.md) for details.

### **Development Setup**
```bash
# Clone repository
git clone https://github.com/dave2k77/hpfracc.git
cd hpfracc

# Create virtual environment
conda create -n hpfracc_dev python=3.9
conda activate hpfracc_dev

# Install development dependencies
pip install -e .[dev]
```

## πŸ“„ **License**

This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.

## πŸ™ **Acknowledgments**

- **University of Reading**: Department of Biomedical Engineering
- **Open Source Community**: Contributors and maintainers
- **Research Community**: Academic and industrial partners

## πŸ“ž **Contact**

- **Email**: [d.r.chin@pgr.reading.ac.uk](mailto:d.r.chin@pgr.reading.ac.uk)
- **GitHub**: [@dave2k77](https://github.com/dave2k77)
- **Project**: [HPFRACC Repository](https://github.com/dave2k77/hpfracc)

---

**HPFRACC** - Advancing fractional calculus through high-performance computing and machine learning integration.

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "hpfracc",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.8",
    "maintainer_email": "\"Davian R. Chin\" <d.r.chin@pgr.reading.ac.uk>",
    "keywords": "fractional-calculus, numerical-methods, machine-learning, graph-neural-networks, jax, pytorch, numba, scientific-computing, mathematics, deep-learning",
    "author": null,
    "author_email": "\"Davian R. Chin\" <d.r.chin@pgr.reading.ac.uk>",
    "download_url": "https://files.pythonhosted.org/packages/29/6a/88b48d7c3d44212c1c639a3ce8bb71cd2df46973fb63aebcfc9323709e72/hpfracc-1.1.2.tar.gz",
    "platform": null,
    "description": "# HPFRACC - High-Performance Fractional Calculus Library\r\n\r\n[![PyPI version](https://badge.fury.io/py/hpfracc.svg)](https://badge.fury.io/py/hpfracc)\r\n[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)\r\n[![Python 3.8+](https://img.shields.io/badge/python-3.8+-blue.svg)](https://www.python.org/downloads/)\r\n[![Documentation](https://img.shields.io/badge/docs-latest-brightgreen.svg)](https://hpfracc.readthedocs.io/)\r\n\r\n## \ud83d\udc68\u200d\ud83d\udcbb **Author & Developer**\r\n\r\n**Davian R. Chin**  \r\nDepartment of Biomedical Engineering  \r\nUniversity of Reading  \r\nEmail: [d.r.chin@pgr.reading.ac.uk](mailto:d.r.chin@pgr.reading.ac.uk)  \r\nGitHub: [@dave2k77](https://github.com/dave2k77)\r\n\r\n## \ud83d\ude80 **Overview**\r\n\r\nHPFRACC (High-Performance Fractional Calculus Library) is a comprehensive Python library that provides high-performance implementations of fractional calculus operations, advanced numerical methods, and machine learning integration with fractional derivatives.\r\n\r\n## \u2728 **Key Features**\r\n\r\n### \ud83d\udd2c **Core Fractional Calculus**\r\n- **Multiple Definitions**: Riemann-Liouville, Caputo, Gr\u00fcnwald-Letnikov, and more\r\n- **High-Performance Algorithms**: Optimized implementations for speed and accuracy\r\n- **GPU Acceleration**: CUDA support for large-scale computations\r\n- **Advanced Methods**: Mellin transforms, fractional differential equations, and special functions\r\n\r\n### \ud83e\udd16 **Machine Learning Integration**\r\n- **Multi-Backend Support**: Seamless integration with PyTorch, JAX, and NUMBA\r\n- **Fractional Neural Networks**: Core networks with fractional calculus integration\r\n- **Fractional Attention Mechanisms**: Multi-head attention with fractional derivatives\r\n- **Graph Neural Networks**: Fractional GNN architectures for graph learning tasks\r\n- **Comprehensive ML Components**: Loss functions, optimizers, and layers (in development)\r\n\r\n### \ud83c\udfaf **Performance & Usability**\r\n- **Cross-Platform**: Windows, macOS, and Linux support\r\n- **Extensive Documentation**: Comprehensive guides and examples\r\n- **Active Development**: Regular updates and improvements\r\n- **Research-Ready**: Designed for academic and industrial applications\r\n\r\n## \ud83c\udfd7\ufe0f **Architecture**\r\n\r\n### **Multi-Backend Support**\r\nHPFRACC provides a unified interface across multiple computation backends:\r\n\r\n- **PyTorch**: Full-featured deep learning with GPU acceleration\r\n- **JAX**: High-performance numerical computing with automatic differentiation\r\n- **NUMBA**: JIT compilation for CPU optimization\r\n\r\n### **Core Components**\r\n- **Backend Management**: Automatic detection and seamless switching between backends\r\n- **Unified Tensor Operations**: Consistent API across all backends\r\n- **Fractional Calculus Integration**: Built-in fractional derivatives in all ML components\r\n\r\n## \ud83d\udce6 **Installation**\r\n\r\n### **Basic Installation**\r\n```bash\r\npip install hpfracc\r\n```\r\n\r\n### **Full Installation with ML Dependencies**\r\n```bash\r\npip install hpfracc[ml]\r\n```\r\n\r\n### **Development Installation**\r\n```bash\r\ngit clone https://github.com/dave2k77/hpfracc.git\r\ncd hpfracc\r\npip install -e .\r\n```\r\n\r\n## \ud83d\ude80 **Quick Start**\r\n\r\n### **Basic Fractional Calculus**\r\n```python\r\nfrom hpfracc import FractionalOrder, riemann_liouville\r\n\r\n# Create fractional order\r\nalpha = FractionalOrder(0.5)\r\n\r\n# Compute fractional derivative\r\nresult = riemann_liouville(function, t, alpha)\r\n```\r\n\r\n### **Multi-Backend Neural Networks**\r\n```python\r\nfrom hpfracc.ml import BackendType, FractionalNeuralNetwork\r\nfrom hpfracc.core.definitions import FractionalOrder\r\n\r\n# Create network with JAX backend\r\nnetwork = FractionalNeuralNetwork(\r\n    input_size=10,\r\n    hidden_sizes=[32, 16],\r\n    output_size=2,\r\n    fractional_order=FractionalOrder(0.5),\r\n    backend=BackendType.JAX\r\n)\r\n\r\n# Forward pass with fractional derivatives\r\noutput = network(input_data, use_fractional=True, method=\"RL\")\r\n```\r\n\r\n### **Fractional Attention Mechanism**\r\n```python\r\nfrom hpfracc.ml import FractionalAttention\r\n\r\n# Create attention with fractional calculus\r\nattention = FractionalAttention(\r\n    d_model=64,\r\n    n_heads=8,\r\n    fractional_order=FractionalOrder(0.5),\r\n    backend=BackendType.TORCH\r\n)\r\n\r\n# Apply fractional attention\r\noutput = attention(input_sequence, method=\"RL\")\r\n```\r\n\r\n### **Fractional Graph Neural Networks**\r\n```python\r\nfrom hpfracc.ml import FractionalGNNFactory, BackendType\r\nfrom hpfracc.core.definitions import FractionalOrder\r\n\r\n# Create GNN with fractional calculus\r\ngnn = FractionalGNNFactory.create_model(\r\n    model_type='gcn',  # Options: 'gcn', 'gat', 'sage', 'unet'\r\n    input_dim=16,\r\n    hidden_dim=32,\r\n    output_dim=4,\r\n    fractional_order=FractionalOrder(0.5),\r\n    backend=BackendType.JAX\r\n)\r\n\r\n# Forward pass on graph data\r\noutput = gnn(node_features, edge_index)\r\n```\r\n\r\n## \ud83d\udd27 **Current Status**\r\n\r\n### **\u2705 Fully Working**\r\n- **Core Fractional Calculus**: All mathematical operations and algorithms\r\n- **Backend Management**: Seamless switching between PyTorch, JAX, and NUMBA\r\n- **Core Neural Networks**: FractionalNeuralNetwork with multi-backend support\r\n- **Attention Mechanisms**: FractionalAttention with fractional derivatives\r\n- **Tensor Operations**: Unified API across all backends\r\n- **Graph Neural Networks**: Complete GNN architectures (GCN, GAT, GraphSAGE, U-Net)\r\n\r\n### **\ud83d\udea7 In Development**\r\n- **Advanced Layers**: Conv1D, Conv2D, LSTM, Transformer layers\r\n- **Loss Functions**: Comprehensive loss function library\r\n- **Optimizers**: Fractional gradient-based optimizers\r\n\r\n### **\ud83d\udccb Planned Features**\r\n- **Advanced ML Components**: Complete layer and optimizer library\r\n- **Performance Optimization**: Backend-specific optimizations\r\n- **Research Tools**: Benchmarking and analysis utilities\r\n- **Extended GNN Support**: Additional graph neural network architectures and graph types\r\n\r\n## \ud83d\udcda **Documentation**\r\n\r\n- **User Guide**: [docs/user_guide.md](docs/user_guide.md)\r\n- **API Reference**: [docs/api_reference.md](docs/api_reference.md)\r\n- **Examples**: [examples/](examples/) directory\r\n- **Development Guide**: [README_DEV.md](README_DEV.md)\r\n\r\n## \ud83e\udd1d **Contributing**\r\n\r\nWe welcome contributions! Please see our [Contributing Guidelines](CONTRIBUTING.md) and [Development Guide](README_DEV.md) for details.\r\n\r\n### **Development Setup**\r\n```bash\r\n# Clone repository\r\ngit clone https://github.com/dave2k77/hpfracc.git\r\ncd hpfracc\r\n\r\n# Create virtual environment\r\nconda create -n hpfracc_dev python=3.9\r\nconda activate hpfracc_dev\r\n\r\n# Install development dependencies\r\npip install -e .[dev]\r\n```\r\n\r\n## \ud83d\udcc4 **License**\r\n\r\nThis project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.\r\n\r\n## \ud83d\ude4f **Acknowledgments**\r\n\r\n- **University of Reading**: Department of Biomedical Engineering\r\n- **Open Source Community**: Contributors and maintainers\r\n- **Research Community**: Academic and industrial partners\r\n\r\n## \ud83d\udcde **Contact**\r\n\r\n- **Email**: [d.r.chin@pgr.reading.ac.uk](mailto:d.r.chin@pgr.reading.ac.uk)\r\n- **GitHub**: [@dave2k77](https://github.com/dave2k77)\r\n- **Project**: [HPFRACC Repository](https://github.com/dave2k77/hpfracc)\r\n\r\n---\r\n\r\n**HPFRACC** - Advancing fractional calculus through high-performance computing and machine learning integration.\r\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "High-Performance Fractional Calculus Library with Machine Learning Integration and Graph Neural Networks",
    "version": "1.1.2",
    "project_urls": {
        "Bug Tracker": "https://github.com/dave2k77/fractional_calculus_library/issues",
        "Documentation": "https://fractional-calculus-library.readthedocs.io",
        "Homepage": "https://github.com/dave2k77/fractional_calculus_library",
        "Repository": "https://github.com/dave2k77/fractional_calculus_library.git"
    },
    "split_keywords": [
        "fractional-calculus",
        " numerical-methods",
        " machine-learning",
        " graph-neural-networks",
        " jax",
        " pytorch",
        " numba",
        " scientific-computing",
        " mathematics",
        " deep-learning"
    ],
    "urls": [
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "e3d55b6821481001fa580aee86ff7cca5e261c45d43f8ec53fc4a9b6e149d4bb",
                "md5": "3c90551367343111cdd6653ebb7e2c34",
                "sha256": "342e902405dd740528c27636298d6a1df4f9ae30f63d30bde41e0a9ffeb66909"
            },
            "downloads": -1,
            "filename": "hpfracc-1.1.2-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "3c90551367343111cdd6653ebb7e2c34",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 185192,
            "upload_time": "2025-08-25T04:30:57",
            "upload_time_iso_8601": "2025-08-25T04:30:57.566928Z",
            "url": "https://files.pythonhosted.org/packages/e3/d5/5b6821481001fa580aee86ff7cca5e261c45d43f8ec53fc4a9b6e149d4bb/hpfracc-1.1.2-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": null,
            "digests": {
                "blake2b_256": "296a88b48d7c3d44212c1c639a3ce8bb71cd2df46973fb63aebcfc9323709e72",
                "md5": "491ae2ed2059f3e9b0ddcb852b6be4b9",
                "sha256": "aab2cdea1bcc26b47d11c96147aa3c5bafcc05ceac6e3e063e50e618d6a1549b"
            },
            "downloads": -1,
            "filename": "hpfracc-1.1.2.tar.gz",
            "has_sig": false,
            "md5_digest": "491ae2ed2059f3e9b0ddcb852b6be4b9",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 170172,
            "upload_time": "2025-08-25T04:30:59",
            "upload_time_iso_8601": "2025-08-25T04:30:59.170862Z",
            "url": "https://files.pythonhosted.org/packages/29/6a/88b48d7c3d44212c1c639a3ce8bb71cd2df46973fb63aebcfc9323709e72/hpfracc-1.1.2.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-08-25 04:30:59",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "dave2k77",
    "github_project": "fractional_calculus_library",
    "github_not_found": true,
    "lcname": "hpfracc"
}
        
Elapsed time: 1.19745s