Ensemble Learning and Random Forests

  • Ensemble learning: 일련의 예측기 (ensemble)로부터 예측 수집
    • 가장 좋은 모델 하나보다 더 좋은 예측 취득 가능
    • Ensemble method: 앙상블 학습 알고리즘
  • Random forest: 결정 트리의 앙상블
    • 훈련 세트로부터 무작위로 각기 다른 서브셋을 만들고 일련의 결정 트리 분류기 훈련
    • 모든 개별 트리의 예측 중 가장 많은 선택을 받은 클래스를 예측으로 선정
Read more »

MNIST Dataset

Data Description

MNIST dataset
MNIST dataset

  • Dataset 구성: 0 ~ 9의 손글씨 이미지 ($28\times28=784$)와 label
  • MnistDataset 클래스
    • Raw data $\rightarrow$ Tensor
    • Label, Pixel values, One-hot encoding tensor 반환
  • 목표: 생성기의 생성 이미지가 판별기를 속일 수 있도록 훈련
Read more »

Support Vector Machine (SVM)

  • Linear, nonlinear classification
  • Regression
  • Outlier detection

Linear SVM Classification

  • SVM Classifier: 각 클래스 사이에 가장 폭이 넓은 경계 정의 (large margin classification)
  • Support vector: 분류기의 경계에 위치한 훈련 데이터
    • 분류기의 경계 밖에 훈련 샘플을 더 추가해도 경계가 변화하지 않음
Read more »

Data Structure

  • Definition: Computer science에서 효율적인 접근 및 수정을 위해 자료의 조직, 관리, 저장
    • 데이터 값의 모임, 데이터 간 관계, 데이터에 적용할 수 있는 함수 및 명령
    • 적합한 자료구조 선택을 통해 상대적으로 효율적인 알고리즘 개발 가능
  • 구현에 따른 자료구조
    • List
    • Tuple
    • Linked list
    • Circular linked list
    • Doubly linked list
    • Hash table
  • 형태에 따른 자료구조
    • Linear
      • Stack
      • Queue
      • Deque
    • Non-Linear
      • Graph
      • Tree
Read more »

GAN (Generative Adversarial Network)

Image Generation

  • Traditional neural network: 정보를 감소, 정제, 축약
    • Ex) $28\times28\rightarrow784\ (input)\rightarrow10\rightarrow1\ (output)$
  • Backquery: 기존의 신경망을 반대로 뒤집어 레이블을 통해 이미지 생성 (원핫 인코딩 벡터를 훈련된 네트워크에 넣어 레이블에 맞는 이상적 이미지 생성)
    • Ex) $1\ (input)\rightarrow10\rightarrow784\ (output)\rightarrow28\times28$
    • 같은 원핫 인코딩 벡터인 경우 같은 결과 출력
    • 각 레이블을 나타내는 모든 훈련 데이터의 평균적 이미지 도출 $\rightarrow$ 한계점 (훈련 샘플로 사용 불가)
Read more »

PyTorch

Setup

How to install PyTorch in M1 Mac

1
conda install pytorch torchvision torchaudio -c pytorch-nightly

RIP Kernel

  • conda activate env 이후 jupyter notebook을 통해 import torch를 실행할 경우 위의 사진과 같이 커널이 죽는다.
  • 따라서 아래 명령어를 통해 jupyter notebook에서 커널을 선택할 수 있게 해줘야한다.
1
conda install nb_conda_kernels

Change kernel

  • 위의 모듈 nb_conda_kernels를 통해 모든 가상환경들을 선택해서 jupyter notebook에서 사용할 수 있다.
Read more »

Introduction

한 Part의 각 Body에 상응하는 조건을 정의하고 해석하기 위해 진행

Introduction
  1. Mechanical - Engineering Data: 물질에 대한 성질 정의
  2. Mecahnical - Geometry: 한 Part에 많은 Body 생성 (Python, SpaceClaim)
  3. Mechanical - Model: Mesh 생성
  4. Mechanical - Setup: 각 Body에 상응하는 경계조건 정의 (Python)
  5. Mechanical - Solution: 해석
Read more »

Lee et al., 2019

본 논문에서는 $th_{m,w}$와 $th_{e,w}$의 비교를 통해 롤투롤 슬롯 다이 코팅에서의 소재와 잉크 사이의 계면에서 잉크의 역학을 분석하고 잉크 점도, 유속 및 코팅 갭에 따른 안정적 공정 조건을 정의했다.

  • $th_{m,w}$: The minimum permissible coated layer thickness
  • $th_{i,w}$ The ideal wet thickness of the coated layer
  • $th_{e,w}$ The estimated wet thickness in the steady state
  • $th_{e,d}$ The estimated thickness of the coated layer after drying
Read more »

GigE Vision CMOS Camera

GigE (Gigabit Ethernet) Vision 표준 기반 CMOS (Complementary metal-oxide-semiconductor) 카메라

GigE Vision

GigE (Gigabit Ethernet): 초당 기가비트 (Gbps)의 속도로 이더넷을 통해 데이터를 전송하는 기술

  • 1 Gbps = 125 MB/s (1 Gbit = 125 MB)

GigE Vision: 고성능 산업용 카메라를 위한 인터페이스 표준

  • 이더넷 네트워크를 통해 고속 비디오 및 관련 제어 데이터를 전송하기 위한 framework 제공
  • Internet Protocol (IP) 표준을 기반으로 함

CMOS

CMOS (Complementary metal-oxide-semiconductor): microprocessor 혹은 SRAM 등의 디지털 회로를 구성하는 집적회로로 COS-MOS (Complementary-symmetry metal-oxide-semiconductor)로도 불림

  • 이미지 장치 분야에서는 CIS (CMOS Image Sensor)를 줄여 CMOS라 칭하는 경우가 있으며 기존의 기술인 CCD (Charge Coupled Device)를 대체
  • 빛에 의해 발생한 전자를 전압 형태로 변환해 전송하는 방식
Read more »

Import Packages

1
2
3
4
>>> import torch
>>> import numpy as np
>>> import matplotlib.pyplot as plt
>>> from torch.autograd import Variable

Tensor

Scala (0-Dim Tensor)

1
2
3
4
5
6
>>> x = torch.rand(10)
>>> x.size()
torch.Size([10])
>>> x
tensor([0.8956, 0.5085, 0.8703, 0.2497, 0.2278, 0.9197, 0.5894, 0.1974, 0.6448,
0.6871])
Read more »

Theorical Background

  • Types of Machine Learning
    • Supervised Learning
    • Unsupervised Learning
    • Reinforcement Learning
    • Self Learning
    • Feature Learning
    • Sparse Dictionary Learning
    • Anomaly Detection
    • Association Rules
  • Two Supervised Learning Methods
    • Regression
    • Classification
  • Empirical Risk Minimization
    • Loss and Risk Functions
    • Algorithms
Read more »