fbpx
Sigmoidal
  • Home
  • LinkedIn
  • About me
  • Contact
No Result
View All Result
  • Português
  • Home
  • LinkedIn
  • About me
  • Contact
No Result
View All Result
Sigmoidal
No Result
View All Result

Fundamentals of Image Formation

In this lesson, you'll learn the theory behind image formation and digital images. This article is the first in a series called Computer Vision: Algorithms and Applications.

Carlos Melo by Carlos Melo
March 22, 2023
in Computer Vision
0
181
SHARES
6k
VIEWS
Share on LinkedInShare on FacebookShare on Whatsapp

In a world full of mysteries and wonders, photography stands tall as a phenomenon that captures the ephemeral and eternal in a single moment. Like a silent dance between light and shadow, it invites our imagination to wander through the corridors of time and space. Through a surprisingly simple process, capturing rays of light through an aperture and exposure time, we are led to contemplate photographs that we know will remain everlasting.

The philosopher José Ortega y Gasset once reflected on the passion for truth as the noblest and most inexorable pursuit. And undoubtedly, photography is one of the most sublime expressions of this quest for truth, capturing reality in a fragment of time.

Behind this process lies the magic of matrices, projections, coordinate transformations, and mathematical models that, like invisible threads, weave the tapestry between the reality captured by a camera lens and the bright pixels on your screen.

But to understand how it’s possible to mathematically model the visual world, with all its richness of detail, we must first understand why vision is so complex and challenging. In this first article of the series “Computer Vision: Algorithms and Applications,” I want to invite you to discover how machines see an image and how an image is formed.

The challenges in Computer Vision

Computer vision is a fascinating field that seeks to develop mathematical techniques capable of reproducing the three-dimensional perception of the world around us. Richard Szeliski, in his book “Computer Vision: Algorithms and Applications,” describes how, with apparent ease, we perceive the three-dimensional structure of the world around us and the richness of detail we can extract from a simple image. However, computer vision faces difficulties in reproducing this level of detail and accuracy.

Szeliski points out that, despite advances in computer vision techniques over the past decades, we still can’t make a computer explain an image with the same level of detail as a two-year-old child. Vision is an inverse problem, where we seek to recover unknown information from insufficient data to fully specify the solution. To solve this problem, it is necessary to resort to models based on physics and probability, or machine learning with large sets of examples.

Schematic representing the physical principle of optical remote sensing, through the interaction between the surface, solar energy, and sensor.

Modeling the visual world in all its complexity is a greater challenge than, for example, modeling the vocal tract that produces spoken sounds. Computer vision seeks to describe and reconstruct properties such as shape, lighting, and color distribution from one or more images, something humans and animals do with ease, while computer vision algorithms are prone to errors.

How an Image is Formed

Before analyzing and manipulating images, it’s essential to understand the image formation process. As examples of components in the process of producing a given image, Szeliski (2022) cites:

  1. Perspective projection: The way three-dimensional objects are projected onto a two-dimensional image, taking into account the position and orientation of the objects relative to the camera.
  2. Light scattering after hitting the surface: The way light scatters after interacting with the surface of objects, influencing the appearance of colors and shadows in the image.
  3. Lens optics: The process by which light passes through a lens, affecting image formation due to refraction and other optical phenomena.
  4. Bayer color filter array: A color filter pattern used in most digital cameras to capture colors at each pixel, allowing for the reconstruction of the original colors of the image.

Regarding the image formation process, it’s quite simple geometrically. An object reflects the light that strikes it, and this light is captured by a sensor, forming an image after a certain exposure time. But if it were that simple, given the large number of light rays coming from so many different angles, our sensor wouldn’t be able to focus on anything and would only display a certain luminous blur.

To ensure that each part of the scene strikes only one point of the sensor, it’s possible to introduce an optical barrier with a hole that allows only a portion of the light rays to pass through, reducing blur and providing a sharper image. This hole placed in the barrier is called an aperture or pinhole, and it’s crucial for forming a sharp image, allowing cameras and other image capture devices to function properly.

A photographic camera that does not have a lens is known as a “pinhole” camera, which means “pinhole”.

This principle of physics, known as the camera obscura, serves as the basis for the construction of any photographic camera. An ideal pinhole camera model has an infinitely small hole to obtain an infinitely sharp image.

However, the problem with pinhole cameras is that there is a trade-off between sharpness and brightness. The smaller the hole, the sharper the image. But since the amount of light passing through is smaller, it’s necessary to increase the exposure time.

Moreover, if the hole is of the same order of magnitude as the wavelength of light, we will have the effect of diffraction, which ends up distorting the image. In practice, a hole smaller than 0.3 mm will cause interference in light waves, making the image blurry.

The solution to this problem is the use of lenses. In this case, a thin converging lens will allow the ray passing through the center of the lens not to be deflected and all rays parallel to the optical axis to intersect at a single point (focal point).

The Magic of Lenses in Image Formation

Lenses are essential optical elements in image formation, as they allow more light to be captured by the sensor while still maintaining the sharpness of the image. Lenses work by refracting the light that passes through them, directing the light rays to the correct points on the sensor.

In the context of camera calibration, the thin converging lens is used as a simplified model to describe the relationship between the three-dimensional world and the two-dimensional image captured by the camera’s sensor. This theoretical model is useful for understanding the basic principles of geometric optics and simplifying the calculations involved in camera calibration, and it should satisfy two properties:

  1. Rays passing through the Optical Center are not deflected; and
  2. All rays parallel to the Optical Axis converge at the Focal Point.

As we’ll see in the next article, camera calibration involves determining the intrinsic and extrinsic parameters that describe the relationship between the real-world coordinates and the image coordinates. The intrinsic parameters include the focal length, the principal point, and lens distortion, while the extrinsic parameters describe the position and orientation of the camera relative to the world.

Although the thin lens model is a simplification of the actual optical system of a camera, it can be used as a starting point for calibration.

Focus and Focal Length

Focus is one of the main aspects of image formation with lenses. The focal length, represented by f, is the distance between the center of the lens and the focal point, where light rays parallel to the optical axis converge after passing through the lens.

Thin Lens Equation. Source: Davide Scaramuzza (2022).

The focal length is directly related to the lens’s ability to concentrate light and, consequently, influences the sharpness of the image. The focus equation is given by:

    \[ \frac{1}{f} = \frac{1}{z} + \frac{1}{e} \]

where z is the distance between the object and the lens, and e is the distance between the formed image and the lens. This equation describes the relationship between the focal length, the object distance, and the formed image distance.

Aperture and Depth of Field

Aperture is another essential aspect of image formation with lenses. The aperture, usually represented by an f-number value, controls the amount of light that passes through the lens. A smaller f-number value indicates a larger aperture, allowing more light in and resulting in brighter images.

Aperture also affects the depth of field, which is the range of distance at which objects appear sharp in the image. A larger aperture (smaller f-number value) results in a shallower depth of field, making only objects close to the focal plane appear sharp, while objects farther away or closer become blurred.

This characteristic can be useful for creating artistic effects, such as highlighting a foreground object and blurring the background.

Focal Length and Angle of View

The lens’s focal length also affects the angle of view, which is the extent of the scene captured by the camera. Lenses with a shorter focal length have a wider angle of view, while lenses with a longer focal length have a narrower angle of view. Wide-angle lenses, for example, have short focal lengths and are capable of capturing a broad view of the scene. Telephoto lenses, on the other hand, have long focal lengths and are suitable for capturing distant objects with greater detail.

Focal Length & Angle of View guide.

By selecting the appropriate lens, it is possible to adjust the composition and framing of the image, as well as control the amount of light entering the sensor and the depth of field. Furthermore, the use of lenses allows for manipulation of perspective and capturing subtle details that would be impossible to record with a pinhole model.

In summary, the lens is a crucial component in image formation, allowing photographers and filmmakers to control and shape light effectively and creatively. With proper knowledge about lens characteristics and their implications in image formation, it is possible to explore the full potential of cameras and other image capturing devices, creating truly stunning and expressive images.

Capture and Representation of Digital Images

Digital cameras use an array of photodiodes (CCD or CMOS) to convert photons (light energy) into electrons, differing from analog cameras that use photographic film to record images. This technology allows capturing and storing images in digital format, simplifying the processing and sharing of photos.

Digital images are organized as a matrix of pixels, where each pixel represents the light intensity at a specific point in the image. A common example of a digital image is an 8-bit image, in which each pixel has an intensity value ranging from 0 to 255. This range of values is a result of using 8 bits to represent intensity, which allows a total of 2^8 = 256 distinct values for each pixel.

Digital images are organized as a matrix of pixels, where each pixel represents the light intensity at a specific point in the image. A common example of a digital image is an 8-bit image, in which each pixel has an intensity value ranging from 0 to 255. This range of values is a result of using 8 bits to represent intensity, which allows a total of 2^8 = 256 distinct values for each pixel.

No modelo RGB, atribui-se um valor de intensidade a cada pixel. No caso das imagens coloridas de 8 bits por canal, os valores de intensidade variam de 0 (preto) a 255 (branco) para cada um dos componentes das cores vermelho, verde e azul.

In the figure above, we see an example of how a machine would “see” a Brazilian Air Force aircraft. In this case, each pixel has a vector of values associated with each of the RGB channels.

Digital cameras typically adopt an RGB color detection system, where each color is represented by a specific channel (red, green, and blue). One of the most common methods for capturing these colors is the Bayer pattern, developed by Bryce Bayer in 1976 while working at Kodak. The Bayer pattern consists of an alternating array of RGB filters placed over the pixel array.

It is interesting to note that the number of green filters is twice that of red and blue filters, as the luminance signal is mainly determined by the green values, and the human visual system is much more sensitive to spatial differences in luminance than chrominance. For each pixel, missing color components can be estimated from neighboring values through interpolation – a process known as demosaicing.

Bayer Filter Pattern Scheme, showing the interaction between visible light, color filters, microlenses, and sensor in capturing vibrant and detailed colors in digital cameras.

However, it is important to emphasize that this is just a common example. In practice, a digital image can have more bits and more channels. Besides the RGB color space, there are several other color spaces, such as YUV, which can also be used in the representation and processing of digital images.

For example, during the period I worked at the Space Operations Center, I received monochromatic images with radiometric resolution of 10 bits per pixel and hyperspectral images with hundreds of channels for analysis.

Summary

This article presented the fundamentals of image formation, exploring the challenges of computer vision, the optical process of capture, the relevance of lenses, and the representation of digital images.

In the second article of this series, I will teach you how to implement a practical example in Python to convert the coordinates of a real 3D object to a 2D image, and how to perform camera calibration (one of the most important areas in Computer Vision).

 

References

  1. Szeliski, R. (2020). Computer Vision: Algorithms and Applications. Springer.
  2. Gonzalez, R. C., & Woods, R. E. (2018). Digital Image Processing. Pearson Education.
Share13Share72Send
Next Post

Build a Surveillance System with Computer Vision and Deep Learning

Carlos Melo

Carlos Melo

Computer Vision Engineer with a degree in Aeronautical Sciences from the Air Force Academy (AFA), Master in Aerospace Engineering from the Technological Institute of Aeronautics (ITA), and founder of Sigmoidal.

Related Posts

Blog

What is Sampling and Quantization in Image Processing

by Carlos Melo
June 20, 2025
Como equalizar histograma de imagens com OpenCV e Python
Computer Vision

Histogram Equalization with OpenCV and Python

by Carlos Melo
July 16, 2024
How to Train YOLOv9 on Custom Dataset
Computer Vision

How to Train YOLOv9 on Custom Dataset – A Complete Tutorial

by Carlos Melo
February 29, 2024
YOLOv9 para detecção de Objetos
Blog

YOLOv9: A Step-by-Step Tutorial for Object Detection

by Carlos Melo
February 26, 2024
Depth Anything - Estimativa de Profundidade Monocular
Computer Vision

Depth Estimation on Single Camera with Depth Anything

by Carlos Melo
February 23, 2024
Next Post

Build a Surveillance System with Computer Vision and Deep Learning

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

  • Trending
  • Comments
  • Latest
Estimativa de Pose Humana com MediaPipe

Real-time Human Pose Estimation using MediaPipe

September 11, 2023
ORB-SLAM 3: A Tool for 3D Mapping and Localization

ORB-SLAM 3: A Tool for 3D Mapping and Localization

April 10, 2023

Build a Surveillance System with Computer Vision and Deep Learning

1
ORB-SLAM 3: A Tool for 3D Mapping and Localization

ORB-SLAM 3: A Tool for 3D Mapping and Localization

1
Point Cloud Processing with Open3D and Python

Point Cloud Processing with Open3D and Python

1

Fundamentals of Image Formation

0

What is Sampling and Quantization in Image Processing

June 20, 2025
Como equalizar histograma de imagens com OpenCV e Python

Histogram Equalization with OpenCV and Python

July 16, 2024
How to Train YOLOv9 on Custom Dataset

How to Train YOLOv9 on Custom Dataset – A Complete Tutorial

February 29, 2024
YOLOv9 para detecção de Objetos

YOLOv9: A Step-by-Step Tutorial for Object Detection

February 26, 2024

Seguir

  • 🐍 PYTHON DO ZERO está de volta!
Agora como curso reconhecido pelo MEC.

Chegou a hora de aprender a habilidade mais poderosa do mercado de trabalho na próxima década.

Se você quer finalmente aprender PYTHON de verdade, sem enrolação e com uma metodologia feita para o mercado, essa é sua chance.

Hoje, comemorando 5 anos do primeiro lançamento da Turma 1, decidi abrir uma exceção histórica.

APRENDA PYTHON DO ZERO! 

🎉Matricule-se agora e garanta a oferta de aniversário do Sigmoidal.
  • 🚀 PROJETO COMPLETO DE DATA SCIENCE (AO VIVO)!

Neste domingo, às 21h, você vai aprender como construir um modelo de precificação de imóveis do zero, usando dados reais e técnicas de Data Science aplicadas ao mercado imobiliário.

Vamos passar pela análise exploratória de dados, entender padrões de preços, criar e validar um modelo de machine learning e discutir como melhorar a acurácia e interpretar os resultados.

💻📊 Uma aula prática e direta para quem quer dominar modelagem preditiva e transformar dados em decisões reais no mercado de imóveis.

>>> LINK NA BIO!

#datascience #cientistadedados #machinelearning
  • 🚀 PYTHON + DATA SCIENCE = Vigilância Aérea em Tempo Real

Treinei uma arquitetura baseada na YOLO (para detecção de objetos) e criei um servidor RTMP com NGINX para conseguir transmitir imagens do DJI Mavic Air 2 e processá-las ao vivo.

Esse projeto é um exemplo de como é possível aprender Data Science na prática!

#datascience #machinelearning #python
  • Até quando você vai continuar estagnado e sem clareza sobre a direção da sua carreira?

A verdade é simples: aprender a programar é a habilidade número um para qualquer profissional hoje, independente da área ou idade.

💻 Saber programar não é exclusividade de quem trabalha em tecnologia.

A pergunta é: você vai continuar no lado de quem espera por soluções prontas e fica preso a tarefas manuais, ou vai migrar para o lado de quem entende a tecnologia e usa programação para crescer, inovar e ganhar vantagem competitiva?

Comece agora. Aprender Python é o primeiro passo para abrir portas que você nem sabia que existiam.

#python #datascience #machinelearning
  • 💰 Você sabe o que faz e quanto ganha um cientista de dados?

Ser Cientista de Dados significa trabalhar com inteligência artificial, estatística e programação para transformar dados em decisões que movimentam negócios e impactam bilhões de pessoas.

É a função que dá vida a recomendações personalizadas, modelos preditivos e sistemas inteligentes que mudam a forma como empresas inovam.

E não é apenas fascinante...

💼💰 É também uma das carreiras mais bem remuneradas da área de tecnologia!

Se você quer uma carreira com futuro, relevância e excelente retorno financeiro, Data Science é o caminho certo!

#cientistadedados #datascience #python
  • Você colocaria fraldas do lado das cervejas no seu supermercado? 🤔

Parece estranho, mas foi exatamente essa descoberta que mudou as vendas do Walmart.

Os cientistas de dados da empresa analisaram milhões de transações com uma técnica de Data Mining que identifica padrões de compra e combinações inesperadas de produtos.

Então, usando algoritmos da Data Science, cruzaram dados de horário, perfil de cliente e itens comprados juntos.

Encontraram algo curioso: homens que passavam no mercado após as 18h para comprar fraldas, muitas vezes no caminho de casa, também compravam cerveja 🍺.

O Walmart testou a hipótese: colocou fraldas perto da seção de cervejas.

O resultado? As vendas de cerveja dispararam. 🚀

Esse é um exemplo clássico de como Data Science gera impacto direto no negócio.

Não é sobre algoritmos complexos apenas; é sobre transformar dados históricos em decisões inteligentes e lucrativas.

#datascience #cientistadedados #machinelearning
  • Conheça as formações da Academia Sigmoidal.

Nossos programas unem rigor acadêmico, prática aplicada e dupla certificação internacional, preparando você para atuar em Data Science, Visão Computacional e Inteligência Artificial com impacto real no mercado.

🤖 Pós-Graduação em Data Science: Forma Cientistas de Dados e Engenheiros de Machine Learning do zero, com Python, estatística e projetos práticos do mundo real.

👁️ Pós-Graduação em Visão Computacional: Especialize-se em processamento de imagens, Deep Learning, redes neurais e navegação autônoma de drones, tornando-se Engenheiro de Visão Computacional ou Engenheiro de Machine Learning.

📊 MBA em Inteligência Artificial: Voltado a profissionais de qualquer área, ensina a aplicar IA estrategicamente em negócios, usando automação, agentes de IA e IA generativa para inovação e competitividade.

Além do título de Especialista reconhecido pelo MEC, você ainda conquista uma Dupla Certificação Internacional com o STAR Research Institute (EUA).

💬 Interessado em dar o próximo passo para liderar no mercado de tecnologia? Me envie uma mensagem e eu te ajudo pessoalmente com a matrícula.

#DataScience #InteligenciaArtificial #VisaoComputacional
  • Treinar um modelo significa encontrar um bom conjunto de parâmetros. Esse conjunto é definido pela função objetivo, também chamada de função de perda. 👀

O gradient descent é o algoritmo que ajusta esses parâmetros passo a passo. Ele calcula a direção de maior inclinação da função de perda e move o modelo para baixo nessa curva. ⬇️

Se o parâmetro é o peso que multiplica X ou o bias que desloca a reta, ambos são atualizados. Cada iteração reduz o erro, aproximando o modelo da solução ótima.

A intuição é simples: sempre que a função de perda é maior, o gradiente aponta o caminho. O algoritmo segue esse caminho até que não haja mais descida possível. 🔄 

#inteligênciaartificial #datascience #machinelearning
  • Qual a melhor linguagem? PYTHON ou R?

Diretamente do túnel do tempo! Resgatei esse vídeo polêmico de 2021, quem lembra??

#DataScience #Python #R #Programação
  • 🎥 Como começar uma CARREIRA como CIENTISTA DE DADOS

Você já pensou em entrar na área que mais cresce e que paga os melhores salários no mundo da tecnologia?

Domingo você vai descobrir o que realmente faz um Cientista de Dados, quais são as habilidades essenciais e o passo a passo para dar os primeiros passos na carreira.

Eu vou te mostrar um mapa para você sair do zero e se preparar para trabalhar com Data Science em 2026.

📅 Domingo, 28 de setembro
🕖 20:00h (horário de Brasília)
🔗 Link nos Stories

Clique no link dos Stories e receba o link da aula ao vivo!

#datascience #machinelearning #cientistadedados
  • VISÃO COMPUTACIONAL está no centro de um dos avanços mais impressionantes da exploração espacial recente: o pouso autônomo da missão Chang’e-5 na Lua. 🚀🌑

Durante a descida, câmeras de alta resolução e sensores a laser capturavam continuamente o relevo lunar, enquanto algoritmos embarcados processavam as imagens em tempo real para identificar crateras e obstáculos que poderiam comprometer a missão.

Esses algoritmos aplicavam técnicas de detecção de bordas e segmentação, aproximando crateras por elipses e cruzando a análise visual com dados de altímetros. Assim, a IA conseguia selecionar regiões planas e seguras para o pouso, ajustando a trajetória da nave de forma autônoma. 

Esse processo foi indispensável, já que a distância entre Terra e Lua gera atraso de comunicação que inviabiliza controle humano direto em tempo real.

Esse caso ilustra como IA embarcada está deixando de ser apenas uma ferramenta de análise pós-missão para se tornar parte crítica das operações espaciais autônomas em tempo real — um passo essencial para missões em Marte, asteroides e no lado oculto da Lua.

(PS: Vi o Sérgio Sacani, do @spacetoday , postando isso primeiro.)

#visaocomputacional #machinelearning #datascience
  • 🔴Aprenda a MATEMÁTICA por Trás do MACHINE LEARNING

Você já se perguntou como as máquinas aprendem?🤖 

A resposta está na matemática que dá vida ao Machine Learning. E neste vídeo, você vai aprender os conceitos fundamentais que sustentam os algoritmos de inteligência artificial, de forma clara e acessível.

Mais do que apenas fórmulas, a ideia é mostrar como cada peça matemática se conecta para transformar dados em aprendizado. Se você deseja compreender a lógica por trás do funcionamento das máquinas, essa aula é um ótimo ponto de partida.

📅 Domingo, 21 de setembro
🕖 20:00h (horário de Brasília)
🔗 Link nos Stories

#machinelearning #datascience #cientistadedados
  • 🚀 As matrículas estão abertas!
Depois de quase 1 ano, a nova turma da Pós-Graduação em Data Science chegou.

NOVIDADE: agora com Dupla Certificação Internacional:
🇧🇷 Diploma de Especialista reconhecido pelo MEC
🇺🇸 Certificado do STAR Research Institute (EUA)

Aprenda Data Science na prática, domine Machine Learning e IA, e conquiste reconhecimento no Brasil e no mundo.

2025 pode ser o ano em que você dá o passo decisivo para se tornar Cientista de Dados.

🔗 Clique no link da bio e reserve sua vaga!
#datascience #cienciadedados #python
  • Por que o CHATGPT MENTE PARA VOCÊ? 🤔

Já percebeu que o ChatGPT às vezes responde com confiança... mas está errado? 

Isso acontece porque, assim como um aluno em prova, ele prefere chutar do que deixar em branco.
Essas respostas convincentes, mas erradas, são chamadas de alucinações.

E o que o pesquisadores da OpenAI sugerem, é que esse tipo de comportamento aparece porque os testes que treinam e avaliam o modelo premiam o chute e punem a incerteza.

Então, da próxima vez que ele ‘inventar’ algo, lembre-se: não é pessoal, ele apenas for treinado dessa maneira!
#inteligênciaartificial #chatgpt #datascience
  • ChatGPT: um "estagiário de LUXO" para aumentar sua produtividade na programação.

 #programacao #copiloto #produtividade #streamlit #dashboard #tecnologia #devlife
  • Da série “Foi a IA que me deu”, vamos relembrar minha viagem pra Tromsø, na Noruega, 500 km acima da linha do Círculo Polar Ártico. 🌍❄️

No vídeo de hoje, você vai aprender o que é um "fiorde"! 

Como você dormia sem saber o que era um fiorde?? 😅
Instagram Youtube LinkedIn Twitter
Sigmoidal

O melhor conteúdo técnico de Data Science, com projetos práticos e exemplos do mundo real.

Seguir no Instagram

Categories

  • Aerospace Engineering
  • Blog
  • Carreira
  • Computer Vision
  • Data Science
  • Deep Learning
  • Featured
  • Iniciantes
  • Machine Learning
  • Posts

Navegar por Tags

3d 3d machine learning 3d vision apollo 13 bayer filter camera calibration career cientista de dados clahe computer vision custom dataset data science deep learning depth anything depth estimation detecção de objetos digital image processing histogram histogram equalization image formation job lens lente machine learning machine learning engineering nasa object detection open3d opencv pinhole projeto python quantization redes neurais roboflow rocket salário sampling scikit-learn space tensorflow tutorial visão computacional yolov8 yolov9

© 2024 Sigmoidal - Aprenda Data Science, Visão Computacional e Python na prática.

Welcome Back!

Login to your account below

Forgotten Password?

Retrieve your password

Please enter your username or email address to reset your password.

Log In

Add New Playlist

No Result
View All Result
  • Home
  • Cursos
  • Pós-Graduação
  • Blog
  • Sobre Mim
  • Contato
  • Português

© 2024 Sigmoidal - Aprenda Data Science, Visão Computacional e Python na prática.