Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

225 PDF build - need to fix how slides/labs/exercises show up #242

Merged
16 changes: 13 additions & 3 deletions _quarto.yml
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,6 @@ format:
code-link: true
link-external-icon: false
link-external-newwindow: true
callout-appearance: simple
anchor-sections: true
smooth-scroll: false
citations-hover: false
Expand Down Expand Up @@ -292,10 +291,21 @@ format:
}{%
\clearpage
}

crossref:
appendix-title: "Appendix"
appendix-delim: ":"


custom:
- kind: float
reference-prefix: Lab
key: lab
latex-env: lab

- kind: float
reference-prefix: Exercise
key: exr
latex-env: exr

editor:
render-on-save: true
26 changes: 13 additions & 13 deletions contents/ai_for_good/ai_for_good.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ bibliography: ai_for_good.bib
# AI for Good {#sec-ai_for_good}

::: {.content-visible when-format="html"}
Resources: [Slides](#sec-ai-for-good-resource), [Labs](#sec-ai-for-good-resource), [Exercises](#sec-ai-for-good-resource)
Resources: [Slides](#sec-ai-for-good-resource), [Exercises](#sec-ai-for-good-resource), [Labs](#sec-ai-for-good-resource)
:::

![_DALL·E 3 Prompt: Illustration of planet Earth wrapped in shimmering neural networks, with diverse humans and AI robots working together on various projects like planting trees, cleaning the oceans, and developing sustainable energy solutions. The positive and hopeful atmosphere represents a united effort to create a better future._](images/png/cover_ai_good.png)
Expand Down Expand Up @@ -78,7 +78,7 @@ Widespread TinyML applications can help digitize smallholder farms to increase p

With greater investment and integration into rural advisory services, TinyML could transform small-scale agriculture and improve farmers' livelihoods worldwide. The technology effectively brings the benefits of precision agriculture to disconnected regions most in need.

:::{#exr-agri .callout-exercise collapse="true"}
:::{#exr-agri .callout-caution collapse="false"}

### Crop Yield Modeling

Expand All @@ -101,7 +101,7 @@ This creates opportunities for transformative medical tools that are portable, a

Early detection of diseases is one major application. Small sensors paired with TinyML software can identify symptoms before conditions escalate or visible signs appear. For instance, [cough monitors](https://stradoslabs.com/cough-monitoring-and-respiratory-trial-data-collection-landing) with embedded machine learning can pick up on acoustic patterns indicative of respiratory illness, malaria, or tuberculosis. Detecting diseases at onset improves outcomes and reduces healthcare costs.

A detailed example could be given for TinyML monitoring pneumonia in children. Pneumonia is a leading cause of death for children under 5, and detecting it early is critical. A startup called [Respira Labs](https://www.samayhealth.com/) has developed a low-cost wearable audio sensor that uses TinyML algorithms to analyze coughs and identify symptoms of respiratory illnesses like pneumonia. The device contains a microphone sensor and microcontroller that runs a neural network model trained to classify respiratory sounds. It can identify features like wheezing, crackling, and stridor that may indicate pneumonia. The device is designed to be highly accessible - it has a simple strap, requires no battery or charging, and results are provided through LED lights and audio cues.
A detailed example could be given for TinyML monitoring pneumonia in children. Pneumonia is a leading cause of death for children under 5, and detecting it early is critical. A startup called [Respira xColabs](https://www.samayhealth.com/) has developed a low-cost wearable audio sensor that uses TinyML algorithms to analyze coughs and identify symptoms of respiratory illnesses like pneumonia. The device contains a microphone sensor and microcontroller that runs a neural network model trained to classify respiratory sounds. It can identify features like wheezing, crackling, and stridor that may indicate pneumonia. The device is designed to be highly accessible - it has a simple strap, requires no battery or charging, and results are provided through LED lights and audio cues.

Another example involves researchers at UNIFEI in Brazil who have developed a low-cost device that leverages TinyML to monitor heart rhythms. Their innovative solution addresses a critical need - atrial fibrillation and other heart rhythm abnormalities often go undiagnosed due to the prohibitive cost and limited availability of screening tools. The device overcomes these barriers through its ingenious design. It uses an off-the-shelf microcontroller that costs only a few dollars, along with a basic pulse sensor. By minimizing complexity, the device becomes accessible to under-resourced populations. The TinyML algorithm running locally on the microcontroller analyzes pulse data in real-time to detect irregular heart rhythms. This life-saving heart monitoring device demonstrates how TinyML enables powerful AI capabilities to be deployed in cost-effective, user-friendly designs.

Expand All @@ -125,13 +125,13 @@ An on-device algorithm for early and timely life-threatening VA detection will i

The champion, GaTech EIC Lab, obtained 0.972 in $F_\beta$ (F1 score with a higher weight to recall), 1.747 ms in latency, and 26.39 kB in memory footprint with a deep neural network. An ICD with an on-device VA detection algorithm was [implanted in a clinical trial](https://youtu.be/vx2gWzAr85A?t=2359).

:::{#exr-hc .callout-exercise collapse="true"}
:::{#exr-hc .callout-caution collapse="false"}

### Clinical Data: Unlocking Insights with Named Entity Recognition

In this exercise, you'll learn about Named Entity Recognition (NER), a powerful tool for extracting valuable information from clinical text. Using Spark NLP, a specialized library for healthcare NLP, we'll explore how NER models like BiLSTM-CNN-Char and BERT can automatically identify important medical entities such as diagnoses, medications, test results, and more. You'll get hands-on experience applying these techniques with a special focus on oncology-related data extraction, helping you unlock insights about cancer types and treatment details from patient records.

[![](https://colab.research.google.com/assets/colab-badge.png)](https://colab.research.google.com/github/JohnSnowLabs/spark-nlp-workshop/blob/master/tutorials/Certification_Trainings/Healthcare/1.Clinical_Named_Entity_Recognition_Model.ipynb#scrollTo=I08sFJYCxR0Z)
[![](https://colab.research.google.com/assets/colab-badge.png)](https://colab.research.google.com/github/JohnSnowxColabs/spark-nlp-workshop/blob/master/tutorials/Certification_Trainings/Healthcare/1.Clinical_Named_Entity_Recognition_Model.ipynb#scrollTo=I08sFJYCxR0Z)
:::

## Science
Expand Down Expand Up @@ -240,31 +240,31 @@ However, realizing TinyML's full potential requires holistic collaboration. Rese

If cultivated responsibly, TinyML could democratize opportunity and accelerate progress on global priorities from poverty alleviation to climate resilience. The technology represents a new wave of applied AI to empower societies, promote sustainability, and propel humanity toward greater justice, prosperity, and peace. TinyML provides a glimpse into an AI-enabled future that is accessible to all.

## Resources {#sec-ai-for-good-resource .unnumbered}
## Resources {#sec-ai-for-good-resource}

Here is a curated list of resources to support students and instructors in their learning and teaching journeys. We are continuously working on expanding this collection and will be adding new exercises soon.

:::{.callout-slide collapse="false"}
# Slides
:::{.callout-note collapse="false"}
#### Slides

These slides are a valuable tool for instructors to deliver lectures and for students to review the material at their own pace. We encourage students and instructors to leverage these slides to enhance their understanding and facilitate effective knowledge transfer.

* [TinyML for Social Impact.](https://docs.google.com/presentation/d/1gkA6pAPUjPWND9ODgnfhCVzbwVYXdrkTpXsJdZ7hJHY/edit#slide=id.ge94401e7d6_0_81)

:::

:::{.callout-exercise collapse="false"}
# Exercises
:::{.callout-caution collapse="false"}
#### Exercises

- @exr-agri

- @exr-hc
:::

:::{.callout-lab collapse="false"}
# Labs
:::{.callout-warning collapse="false"}
#### Labs

In addition to exercises, we offer a series of hands-on labs allowing students to gain practical experience with embedded AI technologies. These labs provide step-by-step guidance, enabling students to develop their skills in a structured and supportive environment. We are excited to announce that new labs will be available soon, further enriching the learning experience.

*Coming soon.*
* *Coming soon.*
:::
22 changes: 11 additions & 11 deletions contents/benchmarking/benchmarking.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ bibliography: benchmarking.bib
# Benchmarking AI {#sec-benchmarking_ai}

::: {.content-visible when-format="html"}
Resources: [Slides](#sec-benchmarking-ai-resource), [Labs](#sec-benchmarking-ai-resource), [Exercises](#sec-benchmarking-ai-resource)
Resources: [Slides](#sec-benchmarking-ai-resource), [Exercises](#sec-benchmarking-ai-resource), [Labs](#sec-benchmarking-ai-resource)
:::

![_DALL·E 3 Prompt: Photo of a podium set against a tech-themed backdrop. On each tier of the podium, there are AI chips with intricate designs. The top chip has a gold medal hanging from it, the second one has a silver medal, and the third has a bronze medal. Banners with 'AI Olympics' are displayed prominently in the background._](images/png/cover_ai_benchmarking.png)
Expand Down Expand Up @@ -135,7 +135,7 @@ These types of microbenchmarks include zooming into very specific operations or

Example: [DeepBench](https://github.com/baidu-research/DeepBench), introduced by Baidu, is a good example of something that assesses the above. DeepBench assesses the performance of basic operations in deep learning models, providing insights into how different hardware platforms handle neural network training and inference.

:::{#exr-cuda .callout-exercise collapse="true"}
:::{#exr-cuda .callout-caution collapse="false"}

### System Benchmarking - Tensor Operations

Expand Down Expand Up @@ -449,7 +449,7 @@ Metrics: We will measure the following metrics:

By measuring these metrics, we can assess the performance of the object detection model on the edge device and identify any potential bottlenecks or areas for optimization to enhance real-time processing capabilities.

:::{#exr-perf .callout-exercise collapse="true"}
:::{#exr-perf .callout-caution collapse="false"}

### Inference Benchmarks - MLPerf

Expand Down Expand Up @@ -806,12 +806,12 @@ Benchmarking provides the compass to guide progress in AI. By persistently measu

Benchmarking is a continuously evolving topic. The article [The Olympics of AI: Benchmarking Machine Learning Systems](https://towardsdatascience.com/the-olympics-of-ai-benchmarking-machine-learning-systems-c4b2051fbd2b) covers several emerging subfields in AI benchmarking, including robotics, extended reality, and neuromorphic computing that we encourage the reader to pursue.

## Resources {#sec-benchmarking-ai-resource .unnumbered}
## Resources {#sec-benchmarking-ai-resource}

Here is a curated list of resources to support students and instructors in their learning and teaching journeys. We are continuously working on expanding this collection and will add new exercises soon.

:::{.callout-slide collapse="false"}
# Slides
:::{.callout-note collapse="false"}
#### Slides

These slides are a valuable tool for instructors to deliver lectures and for students to review the material at their own pace. We encourage students and instructors to leverage these slides to enhance their understanding and facilitate effective knowledge transfer.

Expand All @@ -821,8 +821,8 @@ These slides are a valuable tool for instructors to deliver lectures and for stu

:::

:::{.callout-exercise collapse="false"}
# Exercises
:::{.callout-caution collapse="false"}
#### Exercises

To reinforce the concepts covered in this chapter, we have curated a set of exercises that challenge students to apply their knowledge and deepen their understanding.

Expand All @@ -831,10 +831,10 @@ To reinforce the concepts covered in this chapter, we have curated a set of exer
* @exr-perf
:::

:::{.callout-lab collapse="false"}
# Labs
:::{.callout-warning collapse="false"}
#### Labs

In addition to exercises, we offer a series of hands-on labs allowing students to gain practical experience with embedded AI technologies. These labs provide step-by-step guidance, enabling students to develop their skills in a structured and supportive environment. We are excited to announce that new labs will be available soon, further enriching the learning experience.

*Coming soon.*
* *Coming soon.*
:::
3 changes: 1 addition & 2 deletions contents/case_studies.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,5 @@

## Learning Objectives

*Coming soon.*

* *Coming soon.*
:::
2 changes: 1 addition & 1 deletion contents/conventions.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ Please follow these conventions as you contribute to this online book:

4. **Interactive Elements:**

- **Exercises and Projects:** Integrate exercises and projects at the end of
- **Colabs and Projects:** Integrate exercises and projects at the end of
each chapter to encourage active learning and practical application of
concepts.
- **Case Studies:** Incorporate case studies to provide a deeper
Expand Down
26 changes: 13 additions & 13 deletions contents/data_engineering/data_engineering.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ bibliography: data_engineering.bib
# Data Engineering {#sec-data_engineering}

::: {.content-visible when-format="html"}
Resources: [Slides](#sec-data-engineering-resource), [Labs](#sec-data-engineering-resource), [Exercises](#sec-data-engineering-resource)
Resources: [Slides](#sec-data-engineering-resource), [Exercises](#sec-data-engineering-resource), [Labs](#sec-data-engineering-resource)
:::

![_DALL·E 3 Prompt: Create a rectangular illustration visualizing the concept of data engineering. Include elements such as raw data sources, data processing pipelines, storage systems, and refined datasets. Show how raw data is transformed through cleaning, processing, and storage to become valuable information that can be analyzed and used for decision-making._](images/png/cover_data_engineering.png)
Expand Down Expand Up @@ -122,7 +122,7 @@ In this context, using KWS as an example, we can break each of the steps out as
7. **Iterative Feedback and Refinement:**
Once a prototype KWS system is developed, it's crucial to test it in real-world scenarios, gather feedback, and iteratively refine the model. This ensures that the system remains aligned with the defined problem and objectives. This is important because the deployment scenarios change over time as things evolve.

:::{#exr-kws .callout-exercise collapse="true"}
:::{#exr-kws .callout-caution collapse="false"}

### Keyword Spotting with TensorFlow Lite Micro

Expand Down Expand Up @@ -173,7 +173,7 @@ Web scraping can yield inconsistent or inaccurate data. For example, the photo i

![A picture of old traffic lights (1914). Credit: [Vox.](https://www.vox.com/2015/8/5/9097713/when-was-the-first-traffic-light-installed)](images/jpg/1914_traffic.jpeg){#fig-traffic-light}

:::{#exr-ws .callout-exercise collapse="true"}
:::{#exr-ws .callout-caution collapse="false"}

### Web Scraping

Expand Down Expand Up @@ -218,7 +218,7 @@ While synthetic data offers numerous advantages, it is essential to use it judic

![Increasing training data size with synthetic data generation. Credit: [AnyLogic](https://www.anylogic.com/features/artificial-intelligence/synthetic-data/).](images/jpg/synthetic_data.jpg){#fig-synthetic-data}

:::{#exr-sd .callout-exercise collapse="true"}
:::{#exr-sd .callout-caution collapse="false"}

### Synthetic Data
Let us learn about synthetic data generation using Generative Adversarial Networks (GANs) on tabular data. We'll take a hands-on approach, diving into the workings of the CTGAN model and applying it to the Synthea dataset from the healthcare domain. From data preprocessing to model training and evaluation, we'll go step-by-step, learning how to create synthetic data, assess its quality, and unlock the potential of GANs for data augmentation and real-world applications.
Expand Down Expand Up @@ -303,7 +303,7 @@ Maintaining the integrity of the data infrastructure is a continuous endeavor. T

There is a boom in data processing pipelines, commonly found in ML operations toolchains, which we will discuss in the MLOps chapter. Briefly, these include frameworks like MLOps by Google Cloud. It provides methods for automation and monitoring at all steps of ML system construction, including integration, testing, releasing, deployment, and infrastructure management. Several mechanisms focus on data processing, an integral part of these systems.

:::{#exr-dp .callout-exercise collapse="true"}
:::{#exr-dp .callout-caution collapse="false"}

### Data Processing

Expand Down Expand Up @@ -460,12 +460,12 @@ Dataset licensing is a multifaceted domain that intersects technology, ethics, a

Data is the fundamental building block of AI systems. Without quality data, even the most advanced machine learning algorithms will fail. Data engineering encompasses the end-to-end process of collecting, storing, processing, and managing data to fuel the development of machine learning models. It begins with clearly defining the core problem and objectives, which guides effective data collection. Data can be sourced from diverse means, including existing datasets, web scraping, crowdsourcing, and synthetic data generation. Each approach involves tradeoffs between cost, speed, privacy, and specificity. Once data is collected, thoughtful labeling through manual or AI-assisted annotation enables the creation of high-quality training datasets. Proper storage in databases, warehouses, or lakes facilitates easy access and analysis. Metadata provides contextual details about the data. Data processing transforms raw data into a clean, consistent format for machine learning model development. Throughout this pipeline, transparency through documentation and provenance tracking is crucial for ethics, auditability, and reproducibility. Data licensing protocols also govern legal data access and use. Key challenges in data engineering include privacy risks, representation gaps, legal restrictions around proprietary data, and the need to balance competing constraints like speed versus quality. By thoughtfully engineering high-quality training data, machine learning practitioners can develop accurate, robust, and responsible AI systems, including embedded and TinyML applications.

## Resources {#sec-data-engineering-resource .unnumbered}
## Resources {#sec-data-engineering-resource}

Here is a curated list of resources to support students and instructors in their learning and teaching journeys. We are continuously working on expanding this collection and will add new exercises soon.

:::{.callout-slide collapse="false"}
# Slides
:::{.callout-note collapse="false"}
#### Slides

These slides are a valuable tool for instructors to deliver lectures and for students to review the material at their own pace. We encourage students and instructors to leverage these slides to enhance their understanding and facilitate effective knowledge transfer.

Expand All @@ -492,8 +492,8 @@ These slides are a valuable tool for instructors to deliver lectures and for stu

:::

:::{.callout-exercise collapse="false"}
# Exercises
:::{.callout-caution collapse="false"}
#### Exercises

To reinforce the concepts covered in this chapter, we have curated a set of exercises that challenge students to apply their knowledge and deepen their understanding.

Expand All @@ -507,10 +507,10 @@ To reinforce the concepts covered in this chapter, we have curated a set of exer

:::

:::{.callout-lab collapse="false"}
# Labs
:::{.callout-warning collapse="false"}
#### Labs

In addition to exercises, we offer a series of hands-on labs allowing students to gain practical experience with embedded AI technologies. These labs provide step-by-step guidance, enabling students to develop their skills in a structured and supportive environment. We are excited to announce that new labs will be available soon, further enriching the learning experience.

*Coming soon.*
* *Coming soon.*
:::
Loading
Loading