Commit ca77b9dc authored by Daniele Picone's avatar Daniele Picone
Browse files

2022 version of the notebook

parent c2e0cec5
%% Cell type:markdown id: tags:
# Laboratory session for the course of Image Analysis
## BE 1
### Duration: 2h
**Instructions:** Submit a **report** for each group (binome) of the session in a unique **notebook**, name it **LabX_Name1_Name2**, with X the number of the lab session and **Name1,2** your surnames. Upload it in the folder corresponding to your group and lab in **git**.
**Deadline submission:** The material report should be submitted within a week from the lab work. The preparation has to be done individually as you will be evaluated on the spot at the **beginning** of the lab.
**Objectives** The objectives of this lab work are:
- to understand how to resample an image using filtering and interpolation
- to understand how to manipulate the contrast and colors for enhancing the aspect of an image
- to observe some properties of the 2-D Discrete Fourier Transform (DFT)
- to use the 2D DFT for filtering
%% Cell type:markdown id: tags:
## Preparation
- We want to reduce an image by a factor of two, that is, to transform an image of size $N \times N$ to a smaller image of size $N/2 \times N/2$ pixels. Briefly explain what are the different intuitive methods that you could apply.
- Let us consider in this work the simple operation of subsampling by a certain factor. For a subsample by a factor of 2, e.g., this is equivalent take every second line and every second column. Consider the image Barbara (see below), what kind of artifacts could appear? Why? How could you improve the results?
**Color space**
- We consider the basis transformation of a RGB image $\mathbf{I}$ (whose red, green and blue channels are denoted, respectively with $\mathbf{I}_R$, $\mathbf{I}_G$ and $\mathbf{I}_B$) to another color space, which is expressed in terms of luminance, yellow-blue chrominance and red-green chrominance (denoted, respectively, with $\mathbf{I}_L$, $\mathbf{I}_{C_1}$ and $I_{C_2}$). The transformation is expressed as follows:
- What is the initial color space and the final one?
- Show how to reconstruct $\mathbf{I}$ from $\mathbf{I}_L$, $\mathbf{I}_{C_1}$ and $\mathbf{I}_{C_2}$.
Hint: The matrix $\mathbf{P}$ define the transformation matrix to the new color space is orthogonal, or in other words, its inverse $\mathbf{P}^{-1}$ is equal to its transpose $\mathbf{P}^*$. Specifically, $\mathbf{P}$ is defined as:
\frac{1}{\sqrt{3}} & \frac{1}{\sqrt{3}} & \frac{1}{\sqrt{3}} \\
\frac{1}{\sqrt{6}} & \frac{1}{\sqrt{6}} & -\frac{2}{\sqrt{6}} \\
\frac{1}{\sqrt{2}} & -\frac{1}{\sqrt{2}} & 0
In the context of real imaging sensors, acquisitions are provided as quantization of physical parameters, such as luminance, which may have wildly different dynamics in the probability distribution of intensity values. Additionally, we may focus on just considering a subset of the intensity range.
- Think about how to estimate these probability distributions with a frequentist approach. How may different clusters of intensities be grouped?
- Think about strategies on how to stretch such distributions to cover the whole range of intensity for visualization.
- What are the advantages and disadvantages of a linear transformation for such stretching?
**Fourier transform**
- Explain how do we extend, mathematically, the concept of monodimensional Fourier transform to two dimensions.
- Explain why the Fourier spectrum is well suited to describe the directionality of textures.
- Explain why is it useful to filter images.
This diff is collapsed.
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment