Skip to main content

It's a Python Deep Learning package

Project description

DLFast: Simplifying Deep Learning with Python

dlfast is a Python deep learning library that's revolutionizing the way we build neural networks. Designed for both beginners and experienced data scientists, dlfast empowers users to create intricate deep learning models effortlessly. With its intuitive API and high-level abstractions, you can construct complex networks with just a few lines of code. The library offers modularity, efficiency, and extensive documentation, making it a powerful tool for anyone looking to harness the potential of deep learning.

ANN

The ANN function is a versatile tool for building and training neural networks with ease. It provides options for various tasks, data preprocessing, model architecture, optimization, and more. Whether you're working on binary classification, multiclass classification, or regression, ANN simplifies the process and offers flexibility in customization.

Parameters

  • X (numpy.ndarray): The feature data.
  • y (numpy.ndarray): The target data.
  • task (str, optional): Specifies the task type. Options are 'binary' (default), 'multiclass', or 'regression'.
  • scaler (str, optional): Specifies the data scaling method. Options are 'standard' (default), 'robust', or 'minmax'.
  • epochs (int, optional): The number of training epochs (default: 10).
  • optimizer (str, optional): Specifies the optimizer. Options are 'Adam' (default) or 'SGD'.
  • activation (str, optional): Specifies the activation functions for input and hidden layers. Format: 'input_activation/hidden_activation' (default: 'relu').
  • layers (tuple, optional): Defines the neural network architecture as a tuple of layer sizes (default: (100, 50, 3)).
  • early_stop (bool, optional): Enables or disables early stopping (default: True).
  • dropout (float, optional): Dropout rate for regularization (default: None).
  • save (bool, optional): Specifies whether to save the model as an h5 file (default: False).

Returns

  • model (tensorflow.python.keras.engine.sequential.Sequential): The trained neural network model.
  • evaluation_results (float): The evaluation results (e.g., accuracy for classification, mean squared error for regression).

Example Usage

from dlfast import ANN
# Assuming you have your X and y data loaded from your dataset
X, y = load_data()

Binary Classification Example:

model, results = ANN(X, y, task='binary', scaler='standard', epochs=20, optimizer='Adam', activation='relu/sigmoid', early_stop=True, dropout=0.2, save=True)

Multiclass Classification Example:

model, results = ANN(X, y, task='multiclass', scaler='standard', epochs=20, optimizer='Adam', activation='relu/softmax', early_stop=True, dropout=0.2, save=True)

Regression Example:

model, results = ANN(X, y, task='regression', scaler='standard', epochs=20, optimizer='Adam', activation='relu/linear', early_stop=True, dropout=0.2, save=True)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dlfast-0.0.1.tar.gz (5.4 kB view details)

Uploaded Source

Built Distribution

dlfast-0.0.1-py3-none-any.whl (5.1 kB view details)

Uploaded Python 3

File details

Details for the file dlfast-0.0.1.tar.gz.

File metadata

  • Download URL: dlfast-0.0.1.tar.gz
  • Upload date:
  • Size: 5.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.18

File hashes

Hashes for dlfast-0.0.1.tar.gz
Algorithm Hash digest
SHA256 097cfee8544e1b4af504cf8eb89afc63cf0ee63c22b618e084a9a4f3e99f0e87
MD5 572cfda0623ea84fac4cc941bbba96c9
BLAKE2b-256 285f3cd852220290b463a42aef68d21bf22ee492d84acca8ce9f5baa41d67a45

See more details on using hashes here.

File details

Details for the file dlfast-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: dlfast-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 5.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.18

File hashes

Hashes for dlfast-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 c37ee31936e0c6d9d19e7a6127ee95d673c49cf0d16809db5490baabb41fd7e2
MD5 330df1dcadba8de77fe31af0aff0dde2
BLAKE2b-256 57a0fc15b43bcb899322b472cf63af15c1154de2f9839948f9dedad50499bafe

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page