Skip to content

Commit 1b395d9

Browse files
authored
Merge branch 'main' into unit2-convnextr-fix
2 parents c61ffc1 + 4890225 commit 1b395d9

44 files changed

Lines changed: 3718 additions & 165 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.github/CODEOWNERS‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,6 @@
77
# modifies files in /chapters/ or /notebooks/, only the here mentioned
88
# and not the global owner(s) will be requested for a review.
99

10-
/chapters/ @merveenoyan
10+
/chapters/ @merveenoyan @johko
1111

12-
/notebooks/ @merveenoyan
12+
/notebooks/ @merveenoyan @johko

‎chapters/en/unit0/welcome/welcome.mdx‎

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ On this page, you can find how to join the learners community, make a submission
1212

1313
To obtain your certification for completing the course, complete the following assignments:
1414

15-
1. Training/fine-tuning a Model
15+
1. Training/fine-tuning a model
1616
2. Building an application and hosting it on Hugging Face Spaces
1717

1818
### Training/fine-tuning a Model
@@ -21,7 +21,8 @@ There are notebooks under the Notebooks/Vision Transformers section. As of now,
2121

2222
The model repository needs to have the following:
2323

24-
1. A properly filled model card, you can check out [here for more information](https://huggingface.co/docs/hub/en/model-cards)
24+
25+
1. A properly filled model card, you can check out [here for more information](https://huggingface.co/docs/hub/en/model-cards).
2526
2. If you trained a model with transformers and pushed it to Hub, the model card will be generated. In that case, edit the card and fill in more details.
2627
3. Add the dataset’s ID to the model card to link the model repository to the dataset repository.
2728

@@ -34,7 +35,7 @@ In this assignment section, you'll be building a Gradio-based application for yo
3435

3536
## Certification 🥇
3637

37-
Once you've finished the assignments — Training/fine-tuning a Model and Creating a Space — please complete the [form](https://forms.gle/isiVSw59oiiHP6pN9) with your name, email, and links to your model and Space repositories to receive your certificate
38+
Once you've finished the assignments — Training/fine-tuning a Model and Creating a Space — please complete the [form](https://forms.gle/isiVSw59oiiHP6pN9) with your name, email, and links to your model and Space repositories to receive your certificate.
3839

3940
## Join the community!
4041

@@ -50,8 +51,8 @@ There are many channels focused on various topics on our Discord server. You wil
5051

5152
As a computer vision course learner, you may find the following set of channels particularly relevant:
5253

53-
- `#computer-vision`: a catch-all channel for everything related to computer vision.
54-
- `#cv-study-group`: a place to exchange ideas, ask questions about specific posts and start discussions.
54+
- `#computer-vision`: a catch-all channel for everything related to computer vision
55+
- `#cv-study-group`: a place to exchange ideas, ask questions about specific posts and start discussions
5556
- `#3d`: a channel to discuss aspects of computer vision specific to 3D computer vision
5657

5758
If you are interested in generative AI, we also invite you to join all channels related to the Diffusion Models: #core-announcements, #discussions, #dev-discussions, and #diff-i-made-this.

‎chapters/en/unit1/chapter1/applications.mdx‎

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
# Applications of Computer Vision
22

3-
In today's world, computer vision systems perform ever more challenging tasks. Some of which are even difficult for humans to do. Let's consider India. Do you know India has the highest number of registered two-wheelers in the world? With that many people, sometimes they forget to use a helmet. This is dangerous and can cause severe injuries to the person. To address these issues, the government of India, in collaboration with other institutions, developed a computer vision system that automatically catches riders without a helmet and their license plate and imposes strict fines against them to discourage people from breaking the law.
3+
In today's world, computer vision systems perform ever more challenging tasks. Some of which are even difficult for humans to do. Let's consider India. Do you know India has the highest number of registered two-wheelers in the world? With that many drivers, some of them forget to use a helmet. This is dangerous practice, and can cause severe injuries. To address this issue, the government of India, in collaboration with other institutions, developed a computer vision system that automatically catches riders without a helmet and their license plate. The system imposes strict fines against them to discourage people from breaking the law.
44

5-
Of course, fining people is not the only application of computer vision. There are many more in different fields, such as healthcare, retail, and other industries. Here, we provide a few high-level examples of computer vision systems.
5+
Of course, fining people is not the only application of computer vision. There are uses across healthcare, retail, and many other industries. Here, we provide a few high-level examples of computer vision systems.
66

77
## A High Level Overview of Computer Vision System with Examples
88

@@ -20,7 +20,7 @@ Computer vision is revolutionizing the retail industry. Many online retailers an
2020

2121
### Quality Control in Assembly Lines
2222

23-
CV in quality control on assembly lines helps achieve higher accuracy, efficiency, and consistency in detecting and rectifying defects, reducing waste, improving product quality, and streamlining manufacturing processes. There are many domains in which this is used; some of them are:
23+
CV in quality control on assembly lines helps achieve higher accuracy, efficiency, and consistency in detecting and rectifying defects, reducing waste, improving product quality, and streamlining manufacturing processes. There are many domains in which this is used:
2424

2525
**Defect detection**: CV systems can analyze products on assembly lines in real-time, identifying defects or irregularities that might not be immediately visible to the human eye. For instance, CV can inspect electronic components, automotive parts, or packaged goods in manufacturing to spot imperfections, scratches, dents, or incorrect assembly. These systems compare the product against a standard reference to determine if it meets quality standards.
2626

@@ -34,7 +34,7 @@ CV in quality control on assembly lines helps achieve higher accuracy, efficienc
3434
<img src="https://huggingface.co/datasets/hf-vision/course-assets/resolve/743a2a115b53f258c9e6bc7744534d9e03b8a124/application_02.png" alt="Example of Tumor Detection in Medical Imaging">
3535
</div>
3636

37-
Medical image analysis involves the application of computer vision and machine learning techniques to interpret and extract information from medical images like X-rays, CT scans, MRIs, ultrasounds, and histopathology slides.
37+
Medical image analysis applies computer vision and machine learning techniques to interpret and extract information from medical images like X-rays, CT scans, MRIs, ultrasounds, and histopathology slides.
3838

3939
- **Diagnostic Assistance**: Computer vision aids in diagnosing diseases and conditions by analyzing medical images. For instance, in radiology, algorithms can detect abnormalities such as tumors and fractures in X-rays or MRIs. These systems assist healthcare professionals by highlighting areas of concern or providing quantitative data that helps decision-making.
4040

@@ -69,19 +69,19 @@ Computer Vision systems face a multitude of challenges that arise from the compl
6969
<img src="https://huggingface.co/datasets/hf-vision/course-assets/resolve/743a2a115b53f258c9e6bc7744534d9e03b8a124/ethical_considerations.png" alt="Another summary of Ethical Considerations. Created Isabella Bicalho-Frazeto and Seshu Pavan">
7070
</div>
7171

72-
Ethical considerations in computer vision are of paramount importance as this technology becomes increasingly integrated into various aspects of our lives. It is important to note that ethical consideration existed long before the spread of AI based technologies. It is intrinsecately tied to its birth.
72+
Ethical considerations in computer vision are of paramount importance as this technology becomes increasingly integrated into various aspects of our lives. These ethical considerations have existed long before the spread of AI based technologies. It is intrinsically tied to its birth.
7373

74-
The London Hospital survival predictor is a great example of that. It was created in 1972 and its job was to predict whether patients would recover from a coma. It had a dial that either indictated "survive" or "irreversible brain damage". It was the first applications of patter recognition. Most surprisingly, it was one of the early forms of neural networks. Even at its birth, this raised concerned and doctors were advise to not take its input solely and the machine was never used to remove patient's life support.
74+
The London Hospital survival predictor is a great example of that. It was created in 1972 and its job was to predict whether patients would recover from a coma. It had a dial that either indicated "survive" or "irreversible brain damage". It was one of the first applications of pattern recognition, and of artificial neural networks. Even at early stages, this raised concerns. Doctors were advised not to make decisions solely from the predictor's judgements, and the machine was never used to remove patient's life support.
7575

76-
Life has changed between then and now. We lived in a global, digital society. The ethical considerations of a model must keep considered in these lenses too. Today, we talk a lot of about buildin fair models. Fairness, in this context, refers to a property of a model to behave in a equitative manner, without target discrimination or unfair bias against a group of a individual. Where bias refers to the inclination for or against a person or group. This is tricky in practice.
76+
Life has changed between then and now. The world has become a more digital, interconnected place and the ethical considerations for a model must reflect that. Now, we consider fairness and bias in a global perspective. Fairness, in this context, refers to a property of a model to behave in a equitative manner, without target discrimination or unfair bias against a group or individual. Bias refers to the inclination for or against a person or group. Considering fairness and bias can be tricky in practice.
7777

78-
In contrast to performance metrics, there is not a mathematical metric of fairness. To evaluate it, you must understand the problem at hand. To complicate things fowards, bias can pop at any point in model development; on the data, the AI design, the deployment, and the model applications.
78+
In contrast to performance metrics, there is not a mathematical metric of fairness. To evaluate it, you must understand the problem at hand. Making things more complicated, bias can pop at any point in model development; on the data, the AI design, the deployment, and the model applications.
7979

8080
<div class="flex justify-center">
8181
<img src="https://huggingface.co/datasets/hf-vision/course-assets/resolve/743a2a115b53f258c9e6bc7744534d9e03b8a124/fairness.png" alt="Example of accuracy, precision, bias and unfairness in models. Created by Marilia Melo Favalesso and Isabella Bicalho-Frazeto. Adapted with permission by Isabella Bicalho-Frazeto and Seshu Pavan.">
8282
</div>
8383

84-
There are several efforts in this direction, including the systematic report of model risks, limitation and biases in model cards (special files that accopany the model and provide important information on it). There is a lot more to be said on this topic and that is why there is a dedicated chapter on it in this course. However, there are some key concepts will introduce here to provide a high-level overview of some of the ethical considerations behind it. We summarize these in the table below.
84+
There are several efforts to assist this, including the systematic report of model risks, limitation and biases in model cards (special files that accopany the model and provide important information on it). There is a lot more to be said on this topic and that is why there is a dedicated chapter on it in this course. However, there are some key concepts we will introduce here to provide a high-level overview of some of the ethical considerations behind it. We summarize these in the table below.
8585

8686
| Ethical Considerations | Challenges |
8787
|---------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|

‎chapters/en/unit1/feature-extraction/feature-matching.mdx‎

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ Imagine you have a giant box of puzzle pieces, and you're trying to find a speci
88

99
Now that we have an intuitive idea of how brute-force matches are found, let's dive into the algorithms. We are going to use the descriptors that we learned about in the previous chapter to find the matching features in two images.
1010

11-
First install and load libraries
11+
First install and load libraries.
1212

1313
```bash
1414
!pip install opencv-python
@@ -137,13 +137,13 @@ We also create a dictionary to specify the maximum leafs to visit as follows.
137137
search_params = dict(checks=50)
138138
```
139139

140-
Initiate SIFT detector
140+
Initiate SIFT detector.
141141

142142
```python
143143
sift = cv2.SIFT_create()
144144
```
145145

146-
Find the keypoints and descriptors with SIFT
146+
Find the keypoints and descriptors with SIFT.
147147

148148
```python
149149
kp1, des1 = sift.detectAndCompute(img1, None)
@@ -259,7 +259,7 @@ Fm, inliers = cv2.findFundamentalMat(mkpts0, mkpts1, cv2.USAC_MAGSAC, 0.5, 0.999
259259
inliers = inliers > 0
260260
```
261261

262-
Finally, we can visualize the matches
262+
Finally, we can visualize the matches.
263263

264264
```python
265265
draw_LAF_matches(

‎chapters/en/unit1/image_and_imaging/examples-preprocess.mdx‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ In digital image processing, operations on images are diverse and can be categor
99
- Statistical
1010
- Geometrical
1111
- Mathematical
12-
- Transform operations.
12+
- Transform operations
1313

1414
Each category encompasses different techniques, such as morphological operations under logical operations or fourier transforms and principal component analysis (PCA) under transforms. In this context, we refer to morphology as the group of operations that use structuring elements to generate images of the same size by looking into the values of the pixel neighborhood. Understanding the distinction between element-wise and matrix operations is important in image manipulation. Element-wise operations, such as raising an image to a power or dividing it by another image, involve processing each pixel individually. This pixel-based approach contrasts with matrix operations, which utilize matrix theory for image manipulation. Having said that, you can do whatever you want with images, as they are matrices containing numbers!
1515

0 commit comments

Comments
 (0)