Spaces:
Runtime error
Runtime error
A newer version of the Gradio SDK is available:
6.1.0
metadata
title: SafeTensors Model Converter
emoji: π
colorFrom: blue
colorTo: purple
sdk: gradio
sdk_version: 4.44.0
app_file: app.py
pinned: false
license: mit
SafeTensors Model Converter
A no-code web application for converting machine learning models to the secure SafeTensors format.
Features
- Zero-code conversion: Simple drag-and-drop interface
- Multi-framework support: PyTorch and TensorFlow models
- Secure format: Eliminates pickle-based security risks
- Fast and efficient: Optimized conversion process
Supported Model Formats
PyTorch
.ptfiles (PyTorch model files).pthfiles (PyTorch checkpoint files)
TensorFlow
.h5files (Keras HDF5 format)- SavedModel directories (upload as .zip)
How to Use
- Select your model's framework (PyTorch or TensorFlow)
- Upload your model file
- Click "Convert to SafeTensors"
- Download your converted model
Why SafeTensors?
SafeTensors is a new simple format for storing tensors safely (as opposed to pickle) and that is still fast (zero-copy).
Benefits:
- Security: No arbitrary code execution during loading
- Speed: Faster loading with zero-copy deserialization
- Memory efficiency: Reduced memory usage
- Cross-platform: Works across different ML frameworks
Local Development
```bash pip install -r requirements.txt python app.py ```
Deployment
This app is designed to run on Hugging Face Spaces. Simply:
- Create a new Space on Hugging Face
- Upload these files to your Space
- Your app will automatically deploy!
License
MIT License - feel free to use and modify as needed.