Artificial Intelligence/Computer Vision


오늘 글은 Energy-Based Model(EBM)이 무엇인지,왜 “에너지(Energy)”라는 개념을 통해 확률분포를 정의하면 강력한 생성 모델이 될 수 있는지,그리고 학습(Training) & 샘플링(Sampling) 단계에서 정규화 상수 $Z(\theta)$ 계산을 어떻게 우회하는지에 대한 내용을 정리해보았습니다. 에너지 기반 모델(EBM)의 핵심 수식과 개념, 역사, 학습·샘플링 방법, 확장 가능성 등을 추가적으로 정리해보았습니다.특히 Boltzmann 분포, MCMC(Langevin Dynamics, Metropolis–Hastings 등), 학습 시 발생하는 수식(Gradient) 등을 자세히 다룹니다. 시작합니다. 1. 개요 (Description)에너지 기반 모델(Energy-based..


아래 글은 Score Function이 무엇이며, 이를 이용해 Score Matching으로 어떻게 확률분포를 추정하는지, 그리고이 아이디어가 Diffusion Model(특히 SDE 기반 Score-based Generative Model)에서 왜 중요한 역할을 하는지를 다룹니다.가능한 한 기초적인 확률 개념부터 차근차근 설명하고,Yang Song님의 블로그(2019/ssm)을 참고하였습니다. 차근차근 봅시다. 1. 확률과 분포, 그리고 Score 개념 1-1. 확률분포 $p(x)$와 그 로그 $\log p(x)$ 확률분포 (probability distribution) 란?어떤 데이터(또는 변수) $x$가 가질 수 있는 값들에 대해, 얼마나 자주 (혹은 얼마나 가능성 높게) 나타나는지를 기술예$p(x..


아래 글은 Langevin Dynamics와 이를 이해하기 위한 배경 수학(특히 SDE, 확률분포, Fokker–Planck 방정식 등)를컴퓨터공학(CS) 전공자가 조금 더 직관적으로 이해할 수 있도록 풀어서 설명한 글입니다.갑자기 SDE가 뭐고, 확률분포 $p$ 는 무엇이며, 왜 이렇게 식이 복잡해지는지"에 대한 기본 개념 정리와 함께, Langevin Equation이 무엇이고 어떻게 샘플링에 사용되는지를 다룹니다. 앞서 설명드린 글들을 다시 한 번 짚고 넘어가기에, 더 자세한 설명이 필요하신 분은 앞 포스팅을 이용해주시면 감사하겠습니다. Background1 : ODE to SDE1-1. ODE는 무엇인가? ODE (Ordinary Differential Equation)"시간에 따른 변화"를 ..

Euler’s method(오일러 기법) Euler’s method(오일러 기법)은 초기 조건(Initial Condition)을 알고 있는 상미분방정식(ODE)의 해를 근사하기 위한 가장 간단한 형태의 수치해석(Numerical Analysis) 기법입니다. 즉, ODE에 의해 결정되는 벡터장의 방향(미분의 정보)을 따라 아주 작은 스텝으로 이동함으로써, 전체 해(커브)를 단계적으로 근사해 나가는 방식입니다.Diffusion Model이나 Score-based Generative Model을 이해하기 위해서는, 역방향 과정(Reverse Process)을 해석할 때 ODE(또는 확률적 미분방정식 SDE)에 대한 수치해가 중요합니다. Euler’s method는 이러한 수치해 기법 중 가장 기초가 되는 ..

1. ODE(Ordinary Differential Equation)1-1. ODE란 무엇인가?ODE(Ordinary Differential Equation)는 어떤 변수(미지함수) $\mathbf{x}(t)$ 와 그 미분 $\frac{d\mathbf{x}(t)}{dt}$ 이 등장하는 미분방정식을 의미합니다. 가장 기본적인 형태는 다음과 같습니다. $\frac{d\mathbf{x}(t)}{dt}$ $ = f(\mathbf{x}(t), t)$$\mathbf{x}(t)$: 시간 $t$에서의 함수값$\frac{d\mathbf{x}(t)}{dt}$: $\mathbf{x}(t)$ 가 $t$에 따라 변하는 비율즉, "ODE를 푼다"는 것은 "위 식을 만족하는 함수 $\mathbf{x}(t)$ 를 찾는 것"과 같습..


https://learning.oreilly.com/library/view/hands-on-generative-ai/9781098149239/cover.html Hands-On Generative AI with Transformers and Diffusion Models- Selection from Hands-On Generative AI with Transformers and Diffusion Models [Book]www.oreilly.com본 포스팅이 문제가 될 시 삭제하겠습니다. 본 Hands-On Generative AI with Transformers and Diffusion Models에 대한 Ebook을 hands-on 해보고 리뷰를 남기려합니다. 최근 diffusion models과 st..


🧑🏻💻용어 정리 Computer vision Color image RGB fullcolor HSV YIQ YUV 지금까지 우리는 Gray Scale의 image들에 대해 다뤘습니다. 이제 Color image processing에 대해 다뤄보죠. Color image processing 실제로 color image가 많이 처리되죠. 지금까지 다룬 흑백은 밝기를 의미하는 것이라고 볼 수 있습니다. 사람은 밝기에 대해 색상처럼 민감하진 않습니다. 사람의 시각은 색상을 잘 구별합니다. 위 사진은 전자기파의 파장에 따른 선을 나타낸 것입니다. 그 중에 사람 눈에 보이는 것이 가시광선 구간입니다. 이렇게 파장에 따라 색이 위와 같이 구분됩니다. 이정도 교양으로 알고 넘어가시면 되겠습니다. 가로축은 파장입니다..


🧑🏻💻용어 정리 Computer vision Image Warping Forward warping Backward inverse warping bilinear interpolation transformation 우리가 지금까지는 Transformation의 종류에 대해 배워봤습니다. Forward warping 위와 같은 2D Transformation을 위한 연산으로 행렬 M으로 표현한다고 했습니다. 이 3 x 3 Matrix인 M을 원본 image의 각 좌표에 곱해주게 되면, 각 pixel에 대해 이동시킨 각 pixel을 얻을 수 있다고 하였습니다. 이제 그 좌표 정보가 우리에게 있다고 했을 때, 해당 이미지를 해당되는 변환된 위치로 변환하는 작업을 해보겠습니다. 위 그림에서, 원본 이미지 f에 ..


🧑🏻💻용어 정리 Computer vision Image Warping Non-Linear Transformation Homogeneous coordinates scaling rotation shearing translation matrix composition Euclidean similarity rigid Affine 이전 시간에는 scaling, shear, rotation 등 linear transformation에 대해 알아보았습니다. 이번에는 non-linear transformation에 대해 알아보겠습니다. Image Warping 먼저 2D translation에 대해 알아보겠습니다. 이것은 non-linear transformation입니다. 위 사진에 대해 다음과 같이 바뀌는 위치를..