Install KerasFactory and get your development environment ready for tabular modeling with Keras 3.
๐ฏ Quick Install
1
pipinstallkerasfactory
๐ง Requirements
Python Version
Python 3.8+ (recommended: Python 3.10+)
Core Dependencies
Keras 3.0+ (TensorFlow backend recommended for testing)
NumPy 1.21+
Pandas 1.3+ (for data handling or tf.DataSet if you have tensorflow)
Optional Dependencies
Matplotlib (for visualization)
Seaborn (for statistical plots)
Scikit-learn (for preprocessing utilities)
๐ Installation Methods
1. Pip Install (Recommended)
12345678
# Latest stable releasepipinstallkerasfactory
# With optional dependenciespipinstallkerasfactory[full]# Specific versionpipinstallkerasfactory==1.0.0
2. Development Install
123456789
# Clone the repositorygitclonehttps://github.com/UnicoLab/KerasFactory.git
cdKerasFactory
# Install in development modepipinstall-e.
# Install with development dependenciespipinstall-e".[dev]"
3. Conda Install
123456
# Create a new environmentcondacreate-nkerasfactorypython=3.10
condaactivatekerasfactory
# Install KerasFactorypipinstallkerasfactory
๐ Verify Installation
Test your installation with this simple script:
1 2 3 4 5 6 7 8 9101112131415
importkerasfromkerasfactory.layersimportTabularAttention# Test basic importprint("โ KerasFactory imported successfully!")# Test layer creationlayer=TabularAttention(num_heads=8,key_dim=64)print("โ TabularAttention layer created!")# Test with sample dataimportnumpyasnpx=np.random.random((32,20))output=layer(x)print(f"โ Layer output shape: {output.shape}")
๐ Troubleshooting
Common Issues
ImportError: No module named 'keras'
12
# Install Keras 3pipinstallkeras>=3.0.0
TensorFlow Backend Issues
12345
# Install TensorFlowpipinstalltensorflow>=2.13.0
# Or use JAX backendpipinstalljaxjaxlib
Memory Issues
12345
# Set memory growth for TensorFlowimporttensorflowastfgpus=tf.config.experimental.list_physical_devices('GPU')ifgpus:tf.config.experimental.set_memory_growth(gpus[0],True)