분류 전체보기
[Python] 패키지 관리
1. requirements.txt - 파이썬으로 프로젝트 구성 시 필요한 환경에 대한 정의 필요- 현재 관리하고 있는 프로젝트를 외부환경에서 실행할 때 환경을 동일하게 하기 위해 필요 a) text 파일 생성# > 도 직접 입력해야 한다.pip freeze > requirements.txt b) text 파일 실행pip install -r requirements.txt
Left & Right Eigenvectors and Eigenvalues
Eigenvalue \( \chi (\lambda) = \textbf{det}(\lambda\textit{I}-A)=0 \) 에서, \( \lambda \in \mathbb{C} \) : \( A \in \mathbb{C}^{n \times n} \) 의 eigenvalue (Right) eigenvector \( \exists\ nonzero \ v \in \mathbb{C}^n \) s.t. \(( \lambda I-A)v = 0 \), i.e., \(Av = \lambda v \) \(v \) : A의 eigenvector (Left) eigenvector \( \exists\ nonzero \ w \in \mathbb{C}^n \) s.t. \( w^{T}(\lambda I-A) = 0 \), i..
Reachability & Controllability
\( \dot{x}(t)=Ax(t) + Bu(t) \) \( y(t) = Cx(t) + Du(t) \) time interval \( [t_i, t_f] \) 동안에 대해 성립한다고 가정하자. State transfer : input \( u : [t_i, t_f] \to \mathbb{R}^m \) 으로 \(x(t_i) \to x(t_f) \) 로 transfer하는 것 Reachability 주어진 initial state \( x(t_0) \) 로부터 모든 final state \( x(t_1) \) 까지 state transfer이 가능할 때 \(x(t)\) is reachable (in t seconds or epochs) CT(Continuous Time) system : \( \dot{x}(..
Linear Quadratic Regulator(LQR)
목적 \( J(U) \) 를 최소화하는 \( u_{0}^{lqr}, \cdots, u_{N-1}^{lqr} \) 찾기 Discrete-time finite horizon discrete-time system : \( x_{t+1}=Ax_{t}+Bu_{t}, x_0=x^{init} \) \( x_{0}, x_{1}, \cdots \) 작은 경우, good regulation or control \( u_{0}, u_{1}, \cdots \) 작은 경우, small input effor or actuator authority Quadratic cost function을 정의하자. \( J(U) = \sum_{\tau =0}^{N-1} (x_\tau^{T}Qx_{\tau}+u_\tau^{T}Ru_{\tau})..
[Machine Learning] TensorFlow를 시작하며
본 문서는 TensorFlow 2.12.0 을 기준으로 작성하였습니다. import tensorflow as tf 1.x와 2.x의 차이점 A. Session과 run의 사라짐 hello = tf.constant("hello, TensorFlow!") print(hello) 2.0 이전까지는 Session 모듈을 실행해야만 연산이 가능했으나 2.0 이후부터는 Session 없이 선언과 동시에 실행이 되는 형태로 바뀌었다. B. placeholder의 사라짐 2.0 이전에서는 아래와 같이 a = tf.placeholder(tf.float32) b = tf.placeholder(tf.float32) add_node = a + b print(sess.run(add_node, feed_dict={a:3, b:2..

[Machine Learning] 환경구축(TensorFlow)
TensorFlow의 설치(23.06.14 기준) 공식 문서를 기준으로 작성하였다. 지원 버전 - Python 3.6 ~ 3.9 - Ubuntu 16.04 이상 - Windows 7 이상 - macOS 10.12.6 이상(GPU 지원 X) 설치과정(GPU를 이용하지 않을 경우) pip install --upgrade pip python3 -m pip install tensorflow # Verify install: python3 -c "import tensorflow as tf; print(tf.reduce_sum(tf.random.normal([1000, 1000])))" 설치버전 확인 python3 import tensorflow as tf tf.__version__