Generative AI Lab

Eight generative-AI labs: architectures, text, image, video, 3D, synthetic data, multimodal, and training and evaluation, with simulators that run in your browser, a learning path and a specialised assistant.

13interactive experiments

Applied projects

Projects with clear steps, expected outputs and evaluation criteria, from beginner to research. We add a GitHub link only when we verified that it exists.

  • 12Projects
Beginner

Small GAN on Fashion-MNIST

Train a small convolutional GAN and compare samples across training stages.

Details and steps

Learning objectives

  • Understand the GAN training loop
  • Observe mode collapse

Required knowledge

  • Basic Python and PyTorch

Implementation steps

  • Load and normalise the data
  • Build G and D
  • Train with the non-saturating loss
  • Save samples every N steps

Expected output

A grid of generated samples and a short stability report.

Evaluation criteria

  • Visual diversity; number of classes represented; FID estimate at a fixed sample size.
Architecture
DCGAN مبسّط
Tools
Python, PyTorch, matplotlib

References

  1. I. Goodfellow, J. Pouget-Abadie, M. Mirza, B. Xu, D. Warde-Farley, S. Ozair, A. Courville, Y. Bengio (2014). Generative Adversarial Networks. Advances in Neural Information Processing Systems 27 (NeurIPS 2014). doi:10.48550/arXiv.1406.2661

Beginner

VAE and latent exploration

Train a 2-D-latent VAE and plot the decoding map.

Details and steps

Learning objectives

  • Understand the ELBO
  • Observe the effect of β

Required knowledge

  • Basic probability and neural networks

Implementation steps

  • Build the encoder and decoder
  • Apply reparameterisation
  • Try different β
  • Plot the latent and the decoding map

Expected output

Latent plots and decoding maps for several β.

Evaluation criteria

  • Reconstruction error; KL; clarity of class separation in the latent.
Architecture
VAE
Tools
Python, PyTorch

References

  1. D. P. Kingma, M. Welling (2014). Auto-Encoding Variational Bayes. International Conference on Learning Representations (ICLR 2014); arXiv:1312.6114. doi:10.48550/arXiv.1312.6114
  2. I. Higgins, L. Matthey, A. Pal, C. Burgess, X. Glorot, M. Botvinick, S. Mohamed, A. Lerchner (2017). beta-VAE: Learning Basic Visual Concepts with a Constrained Variational Framework. International Conference on Learning Representations (ICLR 2017).

Intermediate

A tiny diffusion model

Train a diffusion model on 2-D data or 28×28 images and compare DDPM and DDIM.

Details and steps

Learning objectives

  • Implement the noise-prediction objective
  • Compare samplers

Required knowledge

  • Diffusion models and probability

Implementation steps

  • Define the noise schedule
  • Train on ε prediction
  • Implement DDPM and DDIM
  • Compare step counts and quality

Expected output

Samples and a time/quality comparison of the two samplers.

Evaluation criteria

  • FID or sliced Wasserstein distance; sampling time; repeatability.
Architecture
U-Net صغير أو MLP
Tools
Python, PyTorch

References

  1. J. Ho, A. Jain, P. Abbeel (2020). Denoising Diffusion Probabilistic Models. arXiv:2006.11239 (NeurIPS 2020). doi:10.48550/arXiv.2006.11239
  2. J. Song, C. Meng, S. Ermon (2021). Denoising Diffusion Implicit Models. International Conference on Learning Representations (ICLR 2021). doi:10.48550/arXiv.2010.02502

Beginner

BPE tokenisation for Arabic

Compare tokenisation fertility between Arabic and English text with one tokeniser.

Details and steps

Learning objectives

  • Measure tokens per word
  • Understand tokenisation’s effect on cost

Required knowledge

  • NLP basics

Implementation steps

  • Collect text with a clear licence
  • Train BPE
  • Measure tokens per word in Arabic and English

Expected output

A comparison table and an interpretation of the differences.

Evaluation criteria

  • Consistency across different samples; documentation of the text source and licence.
Architecture
BPE
Tools
Python, مكتبة tokenizers
Datasets
common-crawl

References

  1. R. Sennrich, B. Haddow, A. Birch (2016). Neural Machine Translation of Rare Words with Subword Units. Proceedings of the 54th Annual Meeting of the ACL (Volume 1: Long Papers), pp. 1715–1725. doi:10.18653/v1/P16-1162

Intermediate

A decoding-strategy study

Compare greedy, top-k and top-p on an open-weights language model using repetition and diversity metrics.

Details and steps

Learning objectives

  • Design a comparison experiment
  • Measure repetition and diversity

Required knowledge

  • Language models and inference

Implementation steps

  • Pick a model with a clear licence
  • Fix the seeds
  • Generate samples for each strategy
  • Compute unique n-gram share and repetition

Expected output

A comparison report with tables and examples.

Evaluation criteria

  • Enough samples; confidence intervals; human evaluation on a small sample.
Architecture
Transformer مدرَّب مسبقاً
Tools
Python, Transformers

References

  1. A. Holtzman, J. Buys, L. Du, M. Forbes, Y. Choi (2020). The Curious Case of Neural Text Degeneration. International Conference on Learning Representations (ICLR 2020). doi:10.48550/arXiv.1904.09751

Intermediate

Text-to-image retrieval with CLIP

Build a tiny search engine matching text to images in your own collection.

Details and steps

Learning objectives

  • Understand the shared space
  • Measure retrieval accuracy

Required knowledge

  • Deep learning for images

Implementation steps

  • Load the model
  • Compute image embeddings
  • Compute the query embedding
  • Rank by cosine similarity

Expected output

A simple search interface and a top-k accuracy report.

Evaluation criteria

  • Top-1/Top-5 on a small hand-labelled evaluation set; failure-case analysis.
Architecture
CLIP
Tools
Python, PyTorch, open_clip أو CLIP الرسمي
Datasets
coco

References

  1. A. Radford, J. W. Kim, C. Hallacy, et al. (2021). Learning Transferable Visual Models From Natural Language Supervision. International Conference on Machine Learning (ICML 2021). doi:10.48550/arXiv.2103.00020

Intermediate

Synthetic tabular data and its evaluation

Generate a synthetic copy of UCI Adult and evaluate fidelity, utility and privacy.

Details and steps

Learning objectives

  • Apply TSTR
  • Detect verbatim copies

Required knowledge

  • Statistics, probability and machine learning

Implementation steps

  • Clean the table
  • Train a generator
  • Generate rows
  • Compare correlations, run TSTR and nearest-record checks

Expected output

A quality report with tables, charts and a release recommendation.

Evaluation criteria

  • Correlation error; AUC gap; verbatim duplicate rate; distance to closest record.
Architecture
Copula أو CTGAN
Tools
Python, scikit-learn, مكتبة SDV أو CTGAN
Datasets
uci-adult

References

  1. N. Patki, R. Wedge, K. Veeramachaneni (2016). The Synthetic Data Vault. 2016 IEEE International Conference on Data Science and Advanced Analytics (DSAA), pp. 399–410. doi:10.1109/DSAA.2016.49
  2. L. Xu, M. Skoularidou, A. Cuesta-Infante, K. Veeramachaneni (2019). Modeling Tabular Data using Conditional GAN. Advances in Neural Information Processing Systems 32 (NeurIPS 2019). doi:10.48550/arXiv.1907.00503

Advanced

Mini NeRF on a synthetic scene

Implement a simplified NeRF with positional encoding and volume rendering.

Details and steps

Learning objectives

  • Implement volume rendering
  • Understand the role of positional encoding

Required knowledge

  • Computer graphics and deep learning

Implementation steps

  • Render images with known poses
  • Write the ray generator
  • Implement volume rendering
  • Train with a photometric loss and evaluate on held-out views

Expected output

Rendered novel views and depth maps.

Evaluation criteria

  • PSNR on held-out views; training time; effect of the number of samples.
Architecture
MLP + تضمين موضعي
Tools
Python, PyTorch

References

  1. B. Mildenhall, P. P. Srinivasan, M. Tancik, J. T. Barron, R. Ramamoorthi, R. Ng (2020). NeRF: Representing Scenes as Neural Radiance Fields for View Synthesis. Computer Vision – ECCV 2020, Lecture Notes in Computer Science, pp. 405–421. doi:10.1007/978-3-030-58452-8_24

Advanced

An evaluation suite for generative models

Build a script that computes FD, precision, recall and the copy rate for any generator.

Details and steps

Learning objectives

  • Implement the evaluation metrics
  • Diagnose failures

Required knowledge

  • Statistics and deep learning

Implementation steps

  • Choose a feature encoder
  • Implement FD
  • Implement k-NN precision and recall
  • Add a nearest-neighbour check
  • Test on known failure modes

Expected output

A reproducible package with unit tests and a report.

Evaluation criteria

  • Consistency of the metrics with synthetic failures; seed reproducibility.
Architecture
مرمِّز ميزات + مقاييس
Tools
Python, NumPy, PyTorch
Datasets
cifar-10

References

  1. M. Heusel, H. Ramsauer, T. Unterthiner, B. Nessler, S. Hochreiter (2017). GANs Trained by a Two Time-Scale Update Rule Converge to a Local Nash Equilibrium. Advances in Neural Information Processing Systems 30 (NeurIPS 2017). doi:10.48550/arXiv.1706.08500
  2. T. Kynkäänniemi, T. Karras, S. Laine, J. Lehtinen, T. Aila (2019). Improved Precision and Recall Metric for Assessing Generative Models. Advances in Neural Information Processing Systems 32 (NeurIPS 2019). doi:10.48550/arXiv.1904.06991

Research

A study of guidance’s effect on diversity

Measure the effect of the guidance scale on FID and recall in an open-weights conditional diffusion model.

Details and steps

Learning objectives

  • Design an empirical study
  • Sound statistical reporting

Required knowledge

  • Diffusion models and statistics

Implementation steps

  • Define prompts and sample counts
  • Vary w systematically
  • Compute FID, precision and recall
  • Report confidence intervals

Expected output

A short paper with results and clear limits.

Evaluation criteria

  • Reproducibility; seed-to-seed variance; documenting the model licence.
Architecture
انتشار كامن
Tools
Python, diffusers أو ما يماثلها
Datasets
coco

References

  1. J. Ho, T. Salimans (2022). Classifier-Free Diffusion Guidance. arXiv:2207.12598. doi:10.48550/arXiv.2207.12598
  2. R. Rombach, A. Blattmann, D. Lorenz, P. Esser, B. Ommer (2022). High-Resolution Image Synthesis with Latent Diffusion Models. 2022 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pp. 10674–10685. doi:10.1109/CVPR52688.2022.01042

Research

Privacy audit of a data generator

Implement a membership-inference attack and measure the distance to the closest record on synthetic data.

Details and steps

Learning objectives

  • Understand the limits of empirical tests
  • Relate results to differential privacy

Required knowledge

  • Machine learning and privacy

Implementation steps

  • Split into train/holdout
  • Generate synthetic data
  • Implement the distance attack
  • Evaluate the attack AUC

Expected output

An audit report with recommendations and limits.

Evaluation criteria

  • Attack AUC; comparison to a random baseline; stating what the test cannot prove.
Architecture
هجوم عتبة المسافة
Tools
Python, scikit-learn
Datasets
uci-adult

References

  1. N. Patki, R. Wedge, K. Veeramachaneni (2016). The Synthetic Data Vault. 2016 IEEE International Conference on Data Science and Advanced Analytics (DSAA), pp. 399–410. doi:10.1109/DSAA.2016.49

Beginner

An ethics note for a generative system

Write a short note identifying risks (bias, ownership, deepfakes, leakage) and mitigations for a generative application of your choice.

Details and steps

Learning objectives

  • Identify risks
  • Propose measurable mitigations

Required knowledge

  • No programming required

Implementation steps

  • Describe the application and users
  • List the risks
  • Propose metrics and tests
  • Name who reviews the decision

Expected output

A two-page note.

Evaluation criteria

  • Completeness; clarity of metrics; realism of mitigations.
Tools
محرر نصوص

Related DLArabic sections