Useful packages for DL
Project description
FusionLab
FusionLab is an open-source frameworks built for Deep Learning research written in PyTorch and Tensorflow. The code is easy to read and modify especially for newbie. Feel free to send pull requests :D
Installation
With pip
pip install fusionlab
For Mac M1 chip users
Requirements:
- Apple Mac with M1 chips
- MacOS > 12.6 (Monterey)
Following steps
- Clone this repo
git clone https://github.com/taipingeric/fusionlab.git
cd fusionlab
- (remove anaconda first)
- Install Miniconda
- Miniconda3 macOS Apple M1 64-bit pkg
- Miniconda3 macOS Apple M1 64-bit bash
- Install the xcode-select command-line
xcode-select --install
- Deactivate the base environment
conda deactivate
- Create conda environment using config
conda env create -f ./configs/tf-apple-m1-conda.yaml -n fusionlab
- Replace requirements.txt with requirements-m1.txt
- Install by pip
pip install -r requirements-m1.txt
How to use
import fusionlab as fl
# PyTorch
encoder = fl.encoders.VGG16()
# Tensorflow
encoder = fl.encoders.TFVGG16()
Encoders
Segmentation
import fusionlab as fl
# PyTorch UNet
unet = fl.segmentation.UNet(cin=3, num_cls=10, base_dim=64)
# Tensorflow UNet
import tensorflow as tf
# Binary Segmentation
unet = tf.keras.Sequential([
fl.segmentation.TFUNet(num_cls=1, base_dim=64),
tf.keras.layers.Activation(tf.nn.sigmoid),
])
unet.compile(loss=fl.losses.TFDiceLoss("binary"))
# Multiclass Segmentation
unet = tf.keras.Sequential([
fl.segmentation.TFUNet(num_cls=10, base_dim=64),
tf.keras.layers.Activation(tf.nn.softmax),
])
unet.compile(loss=fl.losses.TFDiceLoss("multiclass"))
- UNet, TFUNet
- ResUNet, TFResUNet
- UNet2plus, TFUNet2plus
Acknowledgements
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
fusionlab-0.0.49.tar.gz
(17.7 kB
view hashes)
Built Distribution
fusionlab-0.0.49-py3-none-any.whl
(34.6 kB
view hashes)
Close
Hashes for fusionlab-0.0.49-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 95eb6f9965bb59ffa14b6db2df4e930f5ab58b9423d8291b1ffd0096ada7ef11 |
|
MD5 | 309781316fa496979d0a56f2465f552e |
|
BLAKE2b-256 | b619f4c283ab69b41f4f2b59390538ecf130bfad4cd4e9836e6d31df7de9176f |