Run the demos

Run the demos#

Install optional dependencies

In order to run the demos, you may need to install per domain dependencies:

  • For AI demos: pip install -r requirements-ai.txt

  • For audio demos: pip install -r requirements-audio.txt

Standard demos

Several demos are available in the src/python/fiatlight/demos folder:

%%bash
tree -I "__pycache__|fiat_settings|priv_experiments|fonts|__init__.py" ../demos/ | grep -v directories
../demos/
├── ai
│   ├── demo_sdxl_meme.py
│   └── demo_sdxl_toon_edges.py
├── audio
│   ├── demo_audio_processing_link.py
│   ├── microphone_gui_demo_link.py
│   └── sound_wave_player_gui_demo_link.py
├── custom_graph
│   └── demo_custom_graph.py
├── hello_rosetta
│   ├── example_validation.py
│   └── hello_rosetta.py
├── images
│   ├── demo_computer_vision.py
│   ├── demo_oil_paint.py
│   ├── old_school_meme.py
│   ├── opencv_wrappers.py
│   └── toon_edges.py
├── math
│   ├── demo_binomial.py
│   ├── demo_float_functions.py
│   ├── demo_plot_array.py
│   └── demo_plot_manual_present.py
├── plots
│   └── demo_matplotlib.py
└── string
    ├── demo_word_count.py
    └── str_functions.py

Notebook demos

You can also run all the demos that are present in the documentation (there are a lot of interesting demos, together with screenshots)

  • install Jupyter: pip install jupyter

  • Launch Jupyter with the following command: jupyter lab

  • After Jupyter is launched, a browser page will open: navigate to the “src/python/fiatlight/doc” folder to find the demos.