- The document discusses how a neural network with one hidden layer can approximate any function from RN to RM to arbitrary precision using universal approximation.
- It provides an example of using a neural network with ReLU activations to approximate a function from R to R. The output is a linear combination of shifted and scaled ReLU units.
- With 4 hidden units, this network architecture can represent a bump function by combining 4 different weighted hidden units.
The concept of limit formalizes the notion of closeness of the function values to a certain value "near" a certain point. Limits behave well with respect to arithmetic--usually. Division by zero is always a problem, and we can't make conclusions about nonexistent limits!
Lesson 14: Derivatives of Logarithmic and Exponential Functions (slides)Matthew Leingang
The exponential function is pretty much the only function whose derivative is itself. The derivative of the natural logarithm function is also beautiful as it fills in an important gap. Finally, the technique of logarithmic differentiation allows us to find derivatives without the product rule.
Understanding the "Chain Rule" for Derivatives by Deriving Your Own VersionJames Smith
Because the Chain Rule can confuse students as much as it helps them solve real problems, we put ourselves in the shoes of the mathematicians who derived it, so that students may understand the motivation for the rule; its limitations; and why textbooks present it in its customary form. We begin by finding the derivative of sin2x without using the Chain Rule. That exercise, having shown that even a comparatively simple compound function can be bothersome to differentiate using the definition of the derivative as a limit, provides the motivation for developing our own formula for the derivative of the general compound function g[f(x)]. In the course of that development, we see why the function f must be continuous at any value of x to which the formula is applied. We finish by comparing our formula to that which is commonly given.
The concept of limit formalizes the notion of closeness of the function values to a certain value "near" a certain point. Limits behave well with respect to arithmetic--usually. Division by zero is always a problem, and we can't make conclusions about nonexistent limits!
Lesson 14: Derivatives of Logarithmic and Exponential Functions (slides)Matthew Leingang
The exponential function is pretty much the only function whose derivative is itself. The derivative of the natural logarithm function is also beautiful as it fills in an important gap. Finally, the technique of logarithmic differentiation allows us to find derivatives without the product rule.
Understanding the "Chain Rule" for Derivatives by Deriving Your Own VersionJames Smith
Because the Chain Rule can confuse students as much as it helps them solve real problems, we put ourselves in the shoes of the mathematicians who derived it, so that students may understand the motivation for the rule; its limitations; and why textbooks present it in its customary form. We begin by finding the derivative of sin2x without using the Chain Rule. That exercise, having shown that even a comparatively simple compound function can be bothersome to differentiate using the definition of the derivative as a limit, provides the motivation for developing our own formula for the derivative of the general compound function g[f(x)]. In the course of that development, we see why the function f must be continuous at any value of x to which the formula is applied. We finish by comparing our formula to that which is commonly given.
These notes are a basic introduction to SVM, assuming almost no prior exposure. They contain some derivations, details, and explanations that not many SVM tutorials usually delve into. Thus, they're meant to augment primary course material (textbook or lecture notes) on SVMs and to help digest the course material.
The Chasm at Depth Four, and Tensor Rank : Old results, new insightscseiitgn
Agrawal and Vinay [FOCS 2008] showed how any polynomial size arithmetic circuit can be thought of as a depth four arithmetic circuit of subexponential size. The resulting circuit size in this simulation was more carefully analyzed by Koiran [TCS 2012] and subsequently by Tavenas [MFCS 2013]. We provide a simple proof of this chain of results. We then abstract the main ingredient to apply it to formulas and constant depth circuits, and show more structured depth reductions for them.In an apriori surprising result, Raz [STOC 2010] showed that for any $n$ and $d$, such that $\omega(1) \leq d \leq O(logn/loglogn)$, constructing explicit tensors $T: [n] \rightarrow F$ of high enough rank would imply superpolynomial lower bounds for arithmetic formulas over the field F. Using the additional structure we obtain from our proof of the depth reduction for arithmetic formulas, we give a new and arguably simpler proof of this connection. We also extend this result for homogeneous formulas to show that, in fact, the connection holds for any d such that $\omega(1) \leq d \leq n^{o(1)}$. Joint work with Mrinal Kumar, Ramprasad Saptharishi and V Vinay.
Here we give an overview of the causes of pinning in multiphase lattice Boltzmann models and propose a stochastic sharpening approach to overcome this spurious phenomenon.
Note on set convergence: We give the definitions of inner and outer limits for sequences of sets in topological and normed spaces and we provide some important facts on set convergence on topological and normed spaces. We juxtapose the notions of the limit superior and limit inferior for sequences of sets and we outline some facts regarding the Painlevé-Kuratowski convergence of set-sequences.
The lattice Boltzmann equation: background, boundary conditions, and Burnett-...Tim Reis
An overview of the lattice Boltzmann equation and a discussion of moment-based boundary conditions. Includes applications to the slip flow regime and the Burnett stress. Some analysis sheds insight into the physical and numerical behaviour of the algorithm.
All of material inside is un-licence, kindly use it for educational only but please do not to commercialize it.
Based on 'ilman nafi'an, hopefully this file beneficially for you.
Thank you.
On Some Geometrical Properties of Proximal Sets and Existence of Best Proximi...BRNSS Publication Hub
The notion of proximal intersection property and diagonal property is introduced and used to establish some existence of the best proximity point for mappings satisfying contractive conditions.
These notes are a basic introduction to SVM, assuming almost no prior exposure. They contain some derivations, details, and explanations that not many SVM tutorials usually delve into. Thus, they're meant to augment primary course material (textbook or lecture notes) on SVMs and to help digest the course material.
The Chasm at Depth Four, and Tensor Rank : Old results, new insightscseiitgn
Agrawal and Vinay [FOCS 2008] showed how any polynomial size arithmetic circuit can be thought of as a depth four arithmetic circuit of subexponential size. The resulting circuit size in this simulation was more carefully analyzed by Koiran [TCS 2012] and subsequently by Tavenas [MFCS 2013]. We provide a simple proof of this chain of results. We then abstract the main ingredient to apply it to formulas and constant depth circuits, and show more structured depth reductions for them.In an apriori surprising result, Raz [STOC 2010] showed that for any $n$ and $d$, such that $\omega(1) \leq d \leq O(logn/loglogn)$, constructing explicit tensors $T: [n] \rightarrow F$ of high enough rank would imply superpolynomial lower bounds for arithmetic formulas over the field F. Using the additional structure we obtain from our proof of the depth reduction for arithmetic formulas, we give a new and arguably simpler proof of this connection. We also extend this result for homogeneous formulas to show that, in fact, the connection holds for any d such that $\omega(1) \leq d \leq n^{o(1)}$. Joint work with Mrinal Kumar, Ramprasad Saptharishi and V Vinay.
Here we give an overview of the causes of pinning in multiphase lattice Boltzmann models and propose a stochastic sharpening approach to overcome this spurious phenomenon.
Note on set convergence: We give the definitions of inner and outer limits for sequences of sets in topological and normed spaces and we provide some important facts on set convergence on topological and normed spaces. We juxtapose the notions of the limit superior and limit inferior for sequences of sets and we outline some facts regarding the Painlevé-Kuratowski convergence of set-sequences.
The lattice Boltzmann equation: background, boundary conditions, and Burnett-...Tim Reis
An overview of the lattice Boltzmann equation and a discussion of moment-based boundary conditions. Includes applications to the slip flow regime and the Burnett stress. Some analysis sheds insight into the physical and numerical behaviour of the algorithm.
All of material inside is un-licence, kindly use it for educational only but please do not to commercialize it.
Based on 'ilman nafi'an, hopefully this file beneficially for you.
Thank you.
On Some Geometrical Properties of Proximal Sets and Existence of Best Proximi...BRNSS Publication Hub
The notion of proximal intersection property and diagonal property is introduced and used to establish some existence of the best proximity point for mappings satisfying contractive conditions.
Cosmetic shop management system project report.pdfKamal Acharya
Buying new cosmetic products is difficult. It can even be scary for those who have sensitive skin and are prone to skin trouble. The information needed to alleviate this problem is on the back of each product, but it's thought to interpret those ingredient lists unless you have a background in chemistry.
Instead of buying and hoping for the best, we can use data science to help us predict which products may be good fits for us. It includes various function programs to do the above mentioned tasks.
Data file handling has been effectively used in the program.
The automated cosmetic shop management system should deal with the automation of general workflow and administration process of the shop. The main processes of the system focus on customer's request where the system is able to search the most appropriate products and deliver it to the customers. It should help the employees to quickly identify the list of cosmetic product that have reached the minimum quantity and also keep a track of expired date for each cosmetic product. It should help the employees to find the rack number in which the product is placed.It is also Faster and more efficient way.
We have compiled the most important slides from each speaker's presentation. This year’s compilation, available for free, captures the key insights and contributions shared during the DfMAy 2024 conference.
About
Indigenized remote control interface card suitable for MAFI system CCR equipment. Compatible for IDM8000 CCR. Backplane mounted serial and TCP/Ethernet communication module for CCR remote access. IDM 8000 CCR remote control on serial and TCP protocol.
• Remote control: Parallel or serial interface.
• Compatible with MAFI CCR system.
• Compatible with IDM8000 CCR.
• Compatible with Backplane mount serial communication.
• Compatible with commercial and Defence aviation CCR system.
• Remote control system for accessing CCR and allied system over serial or TCP.
• Indigenized local Support/presence in India.
• Easy in configuration using DIP switches.
Technical Specifications
Indigenized remote control interface card suitable for MAFI system CCR equipment. Compatible for IDM8000 CCR. Backplane mounted serial and TCP/Ethernet communication module for CCR remote access. IDM 8000 CCR remote control on serial and TCP protocol.
Key Features
Indigenized remote control interface card suitable for MAFI system CCR equipment. Compatible for IDM8000 CCR. Backplane mounted serial and TCP/Ethernet communication module for CCR remote access. IDM 8000 CCR remote control on serial and TCP protocol.
• Remote control: Parallel or serial interface
• Compatible with MAFI CCR system
• Copatiable with IDM8000 CCR
• Compatible with Backplane mount serial communication.
• Compatible with commercial and Defence aviation CCR system.
• Remote control system for accessing CCR and allied system over serial or TCP.
• Indigenized local Support/presence in India.
Application
• Remote control: Parallel or serial interface.
• Compatible with MAFI CCR system.
• Compatible with IDM8000 CCR.
• Compatible with Backplane mount serial communication.
• Compatible with commercial and Defence aviation CCR system.
• Remote control system for accessing CCR and allied system over serial or TCP.
• Indigenized local Support/presence in India.
• Easy in configuration using DIP switches.
Overview of the fundamental roles in Hydropower generation and the components involved in wider Electrical Engineering.
This paper presents the design and construction of hydroelectric dams from the hydrologist’s survey of the valley before construction, all aspects and involved disciplines, fluid dynamics, structural engineering, generation and mains frequency regulation to the very transmission of power through the network in the United Kingdom.
Author: Robbie Edward Sayers
Collaborators and co editors: Charlie Sims and Connor Healey.
(C) 2024 Robbie E. Sayers
6th International Conference on Machine Learning & Applications (CMLA 2024)ClaraZara1
6th International Conference on Machine Learning & Applications (CMLA 2024) will provide an excellent international forum for sharing knowledge and results in theory, methodology and applications of on Machine Learning & Applications.
Welcome to WIPAC Monthly the magazine brought to you by the LinkedIn Group Water Industry Process Automation & Control.
In this month's edition, along with this month's industry news to celebrate the 13 years since the group was created we have articles including
A case study of the used of Advanced Process Control at the Wastewater Treatment works at Lleida in Spain
A look back on an article on smart wastewater networks in order to see how the industry has measured up in the interim around the adoption of Digital Transformation in the Water Industry.
Final project report on grocery store management system..pdfKamal Acharya
In today’s fast-changing business environment, it’s extremely important to be able to respond to client needs in the most effective and timely manner. If your customers wish to see your business online and have instant access to your products or services.
Online Grocery Store is an e-commerce website, which retails various grocery products. This project allows viewing various products available enables registered users to purchase desired products instantly using Paytm, UPI payment processor (Instant Pay) and also can place order by using Cash on Delivery (Pay Later) option. This project provides an easy access to Administrators and Managers to view orders placed using Pay Later and Instant Pay options.
In order to develop an e-commerce website, a number of Technologies must be studied and understood. These include multi-tiered architecture, server and client-side scripting techniques, implementation technologies, programming language (such as PHP, HTML, CSS, JavaScript) and MySQL relational databases. This is a project with the objective to develop a basic website where a consumer is provided with a shopping cart website and also to know about the technologies used to develop such a website.
This document will discuss each of the underlying technologies to create and implement an e- commerce website.
Sachpazis:Terzaghi Bearing Capacity Estimation in simple terms with Calculati...Dr.Costas Sachpazis
Terzaghi's soil bearing capacity theory, developed by Karl Terzaghi, is a fundamental principle in geotechnical engineering used to determine the bearing capacity of shallow foundations. This theory provides a method to calculate the ultimate bearing capacity of soil, which is the maximum load per unit area that the soil can support without undergoing shear failure. The Calculation HTML Code included.
NO1 Uk best vashikaran specialist in delhi vashikaran baba near me online vas...Amil Baba Dawood bangali
Contact with Dawood Bhai Just call on +92322-6382012 and we'll help you. We'll solve all your problems within 12 to 24 hours and with 101% guarantee and with astrology systematic. If you want to take any personal or professional advice then also you can call us on +92322-6382012 , ONLINE LOVE PROBLEM & Other all types of Daily Life Problem's.Then CALL or WHATSAPP us on +92322-6382012 and Get all these problems solutions here by Amil Baba DAWOOD BANGALI
#vashikaranspecialist #astrologer #palmistry #amliyaat #taweez #manpasandshadi #horoscope #spiritual #lovelife #lovespell #marriagespell#aamilbabainpakistan #amilbabainkarachi #powerfullblackmagicspell #kalajadumantarspecialist #realamilbaba #AmilbabainPakistan #astrologerincanada #astrologerindubai #lovespellsmaster #kalajaduspecialist #lovespellsthatwork #aamilbabainlahore#blackmagicformarriage #aamilbaba #kalajadu #kalailam #taweez #wazifaexpert #jadumantar #vashikaranspecialist #astrologer #palmistry #amliyaat #taweez #manpasandshadi #horoscope #spiritual #lovelife #lovespell #marriagespell#aamilbabainpakistan #amilbabainkarachi #powerfullblackmagicspell #kalajadumantarspecialist #realamilbaba #AmilbabainPakistan #astrologerincanada #astrologerindubai #lovespellsmaster #kalajaduspecialist #lovespellsthatwork #aamilbabainlahore #blackmagicforlove #blackmagicformarriage #aamilbaba #kalajadu #kalailam #taweez #wazifaexpert #jadumantar #vashikaranspecialist #astrologer #palmistry #amliyaat #taweez #manpasandshadi #horoscope #spiritual #lovelife #lovespell #marriagespell#aamilbabainpakistan #amilbabainkarachi #powerfullblackmagicspell #kalajadumantarspecialist #realamilbaba #AmilbabainPakistan #astrologerincanada #astrologerindubai #lovespellsmaster #kalajaduspecialist #lovespellsthatwork #aamilbabainlahore #Amilbabainuk #amilbabainspain #amilbabaindubai #Amilbabainnorway #amilbabainkrachi #amilbabainlahore #amilbabaingujranwalan #amilbabainislamabad
1. 컴퓨터 비전을 위한 신경망 2
- 신경망 근사화와 볼록 함수
도정찬
Michigan Online, Justin Johnson, Computer Vision, 2021. 01. 29
2. ▪ 아무튼 이전 내용에 이어서 우리는 신경망을 보편적 근사화 universal approximation이라고 부르는 개념으로 수식화를 할수
있는데, 은닉층 하나를 가진 신경망이 있다고 할때, r^n을 r^m으로 근사화시키는 함수라고 할수 있겠습니다. 물론 실제로 분석을
하거나 완전히 나타낼수 수 있는 함수가 있다고 할 수도 있겠지만, 증명하기는 힘들것이고 이런 함수가 있다해도 전체 입력 공간
이 아닌 아주 일부 공간에서만 가능한 연속 함수 일것입니다.
▪ 여기서 어느정도 정확도 arbitrary precision을 가진다는 말은 항상 정확한 클래스로 분류한다는게 아니라 세세한 디테일은 무
시하더라도, 신경망을 입력 공간의 어느정도 구간의 연속 함수로 근사화하여 구할수 있다는걸 말합니다.
한 개의 은닉층을 가진 신경망은 어느 정도의 정학도를 갖는 함수 f : 𝑹𝑵
→ 𝑹𝑴
로 근사시킬수 있다.
보편적 근사화 Universal Approximation
3. 보편적 근사화 Universal Approximation
예시 : 두 층으로 이루어진 렐루 네트워크를 함수 f : R -> R로 근사시켜보자
입력 :
x (1, )
입력 :
y (1, )
1층 가중치 : w (3,1)
1층 편향 : b (3, )
2층 가중치 : u (1,3)
2층 편향 : p (1, )
h1 = max(0, w1 * x + b1)
h2 = max(0, w2 * x + b2)
h3 = max(0, w3 * x + b3)
y = u1 * h1 + u2 * h2 + u3 * h3 + p
y = u1 * max(0, w1 * x + b1)
+ u2 * max(0, w2 * x + b2)
+ u3 * max(0, w3 * x + b3)
+ p
𝑾𝒊 의 부호를 보고 좌/우로 뒤집어 보자
기울기는
𝒖𝒊 ∗ 𝑾𝒊
기울어지는
지점은 𝒃𝒊
▪ ReLU기반 시스템이 어떻게 어떤 형태의 함수로 학습할수 있는지는 대수적으로 생각해볼수 있습니다. 그러면 어떻게 ReLU기
반 신경망이 출력을 계산할까요? 한번 relu 함수를 활성화 함수로 사용하는 완전 연결 신경망을 예시로 살펴봅시다. 이 신경망은
입력으로 실수 하나를 받고, 출력으로 실수 하나를 내보냅니다. 이제 이 신경망의 은닉층을 보면 3개의 유닛, 요소로 되어있습니
다. 그렇다보니 1층의 경우는 벡터 형태의 가중치 행렬을 얻겠습니다.
▪ 왜냐면 입력은 1개이고, 2층에 가중치 행렬도 벡터다 보니, 그 사이에 있는 1층은 벡터 형태가 될것입니다. 2층의 가중치 행렬
도 출력이 1차원 값을 반환하니 행렬이 아닌 벡터 형태가 될겁니다.
출력 y는 스케일링(u * max(0, h))되고, 이동한(+p) ReLU들의 합이 됩니다.
4. 예시 : 두 층으로 이루어진 렐루 네트워크를 함수 f : R -> R로 근사시켜보자
입력 :
x (1, )
입력 :
y (1, )
1층 가중치 : w (3,1)
1층 편향 : b (3, )
2층 가중치 : u (1,3)
2층 편향 : p (1, )
h1 = max(0, w1 * x + b1)
h2 = max(0, w2 * x + b2)
h3 = max(0, w3 * x + b3)
y = u1 * h1 + u2 * h2 + u3 * h3 + p
y = u1 * max(0, w1 * x + b1)
+ u2 * max(0, w2 * x + b2)
+ u3 * max(0, w3 * x + b3)
+ p
출력 y는 스케일링(u * max(0, h))되고, 이동한(+p) ReLU들의 합이 됩니다.
𝑾𝒊 의 부호를 보고 좌/우로 뒤집어 보자
기울기는
𝒖𝒊 ∗ 𝑾𝒊
기울어지는
지점은 𝒃𝒊
▪ 은닉층 각각의 함수적 형태를 정리하면, 첫번째 유닛은 max(0, w1 * x + b1)을 한 것과 같다고 할 수 있고, 이 층의 나머지 유
닛들도 동일한 함수적 형태를 가집니다. 은닉 층의 3 유닛들의 값을 선형 결합하여 출력 y를 구하는데, 이를 2층 가중치 행렬을 u
라고 한다면 최종 출력 y = u1 * h1 + u2 * h2 + u3 * 3 의 형태로 구할수 있을겁니다.
▪ 여기서 알아차릴수 있는 점은 y는 2층 가중치 행렬의 요소 u와 max(0, 1층 가중치 요소 w * 입력 x + 편향 b)인 세 항 합의 형
태라는 점입니다. 각 세 항을 잘 보면 ReLU함수가 평행이동(shift/translated) 이나 스케일링된 형태의 함수로 되어 있습니다.
보편적 근사화 Universal Approximation
5. 예시 : 두 층으로 이루어진 렐루 네트워크를 함수 f : R -> R로 근사시켜보자
𝑾𝒊 의 부호를 부호에 따라
좌우로 뒤집히는 ReLU 함수
편향항 b에 따라 선형적으로
변화하는 지점이 바뀌는 ReLU함수
w과 u에 따라 기울기가 변하는
ReLU 함수
▪ 우선 보면 첫번째 가중치 행렬의 요소인 w1의 부호에 따라서 왼쪽이나 오른쪽으로 뒤집을 수 있을것이고, 평향항을 이용해서
선형적으로 변화하기 시작하는 지점을 조정할 수 있겠습니다. 그리고 평평하지 않은 부분(선형적으로 증감하는 부분)의 기울기는
첫번째 가중치 행렬의 항 w와 두 번째 가중치 행렬의 항 u로 정해지겠습니다.
보편적 근사화 Universal Approximation
6. 예시 : 두 층으로 이루어진 렐루 네트워크를 함수 f : R -> R로 근사시켜보자
입력 :
x (1, )
입력 :
y (1, )
1층 가중치 : w (3,1)
1층 편향 : b (3, )
2층 가중치 : u (1,3)
2층 편향 : p (1, )
h1 = max(0, w1 * x + b1)
h2 = max(0, w2 * x + b2)
h3 = max(0, w3 * x + b3)
y = u1 * h1 + u2 * h2 + u3 * h3 + p
y = u1 * max(0, w1 * x + b1)
+ u2 * max(0, w2 * x + b2)
+ u3 * max(0, w3 * x + b3)
+ p
▪ 이제 신경망 시스템의 개념을 시프트된 relu 함수의 합으로 정리하였습니다. 우리가 좀 더 잘 생각해본다면 이런 식으로 시프팅
을 하고, 조합을 시키면 어떤 종류의 함수나 방법에 대한 근사식을 구할 수 있으며 이를 범프 함수 bump function이라 부릅니다.
▪ 이 범프 함수는 모든 입력에 대해 평평하지만, x가 첫번째로 지정한 값인 s1인 지점에서부터 s2까지 y축으로 t에 도달할 때 까
지 선형적으로 증가합니다. 그 다음 두번째로 지정한 값인 s3에 도달하면 선형적으로 감소하기 시작하여 y축으로 0가되는 x가 s4
인 지점에서부터 쭉 0이 됩니다.
4개의 은닉층 유닛으로
범프 함수를 만들 수 있습니다.
보편적 근사화 Universal Approximation
7. 예시 : 두 층으로 이루어진 렐루 네트워크를 함수 f : R -> R로 근사시켜보자
입력 :
x (1, )
입력 :
y (1, )
1층 가중치 : w (3,1)
1층 편향 : b (3, )
2층 가중치 : u (1,3)
2층 편향 : p (1, )
h1 = max(0, w1 * x + b1)
h2 = max(0, w2 * x + b2)
h3 = max(0, w3 * x + b3)
y = u1 * h1 + u2 * h2 + u3 * h3 + p
y = u1 * max(0, w1 * x + b1)
+ u2 * max(0, w2 * x + b2)
+ u3 * max(0, w3 * x + b3)
+ p
▪ 그 동안 신경망에 대해서 정리했고, 출력이 시프팅/스케일링된 ReLU함수의 선형 결합임을 알았으니, 이제 이 범프 함수를 만들
수가 있겠습니다. 범프 함수를 4개의 다른 가중화된 은닉 유닛을 합하여 만들수가 있겠습니다.
4개의 은닉층 유닛으로
범프 함수를 만들 수 있습니다.
보편적 근사화 Universal Approximation
8. 예시 : 두 층으로 이루어진 렐루 네트워크를 함수 f : R -> R로 근사시켜보자
입력 :
x (1, )
입력 :
y (1, )
1층 가중치 : w (3,1)
1층 편향 : b (3, )
2층 가중치 : u (1,3)
2층 편향 : p (1, )
h1 = max(0, w1 * x + b1)
h2 = max(0, w2 * x + b2)
h3 = max(0, w3 * x + b3)
y = u1 * h1 + u2 * h2 + u3 * h3 + p
y = u1 * max(0, w1 * x + b1)
+ u2 * max(0, w2 * x + b2)
+ u3 * max(0, w3 * x + b3)
+ p
▪ 그리고 경사가 있는 부분의 기울기를 기울기 계산식으로 구할수가 있는데,
4개의 은닉층 유닛으로
범프 함수를 만들 수 있습니다.
보편적 근사화 Universal Approximation
9. 예시 : 두 층으로 이루어진 렐루 네트워크를 함수 f : R -> R로 근사시켜보자
입력 :
x (1, )
입력 :
y (1, )
1층 가중치 : w (3,1)
1층 편향 : b (3, )
2층 가중치 : u (1,3)
2층 편향 : p (1, )
h1 = max(0, w1 * x + b1)
h2 = max(0, w2 * x + b2)
h3 = max(0, w3 * x + b3)
y = u1 * h1 + u2 * h2 + u3 * h3 + p
y = u1 * max(0, w1 * x + b1)
+ u2 * max(0, w2 * x + b2)
+ u3 * max(0, w3 * x + b3)
+ p
▪ 이 기울기 두 개를 구하고 나면, 이제 범프 함수의 첫 번째 부분을 위와 같은 렐루 함수로 나타낼 수 있겠습니다.
4개의 은닉층 유닛으로
범프 함수를 만들 수 있습니다.
보편적 근사화 Universal Approximation
10. 예시 : 두 층으로 이루어진 렐루 네트워크를 함수 f : R -> R로 근사시켜보자
입력 :
x (1, )
입력 :
y (1, )
1층 가중치 : w (3,1)
1층 편향 : b (3, )
2층 가중치 : u (1,3)
2층 편향 : p (1, )
h1 = max(0, w1 * x + b1)
h2 = max(0, w2 * x + b2)
h3 = max(0, w3 * x + b3)
y = u1 * h1 + u2 * h2 + u3 * h3 + p
y = u1 * max(0, w1 * x + b1)
+ u2 * max(0, w2 * x + b2)
+ u3 * max(0, w3 * x + b3)
+ p
▪ 범프 함수의 두번째 파트 같은 경우 저런 형태의 렐루 유닛을 사용하면 되겠죠.
4개의 은닉층 유닛으로
범프 함수를 만들 수 있습니다.
보편적 근사화 Universal Approximation
11. 예시 : 두 층으로 이루어진 렐루 네트워크를 함수 f : R -> R로 근사시켜보자
입력 :
x (1, )
입력 :
y (1, )
1층 가중치 : w (3,1)
1층 편향 : b (3, )
2층 가중치 : u (1,3)
2층 편향 : p (1, )
h1 = max(0, w1 * x + b1)
h2 = max(0, w2 * x + b2)
h3 = max(0, w3 * x + b3)
y = u1 * h1 + u2 * h2 + u3 * h3 + p
y = u1 * max(0, w1 * x + b1)
+ u2 * max(0, w2 * x + b2)
+ u3 * max(0, w3 * x + b3)
+ p
▪ 그리고 세번째 렐루 함수를 추가시키면 대략적인 형태는 만들었지만 계속 내려가고 있죠.
4개의 은닉층 유닛으로
범프 함수를 만들 수 있습니다.
보편적 근사화 Universal Approximation
12. y = u1 * max(0, w1 * x + b1)
+ u2 * max(0, w2 * x + b2)
+ u3 * max(0, w3 * x + b3)
+ p
예시 : 두 층으로 이루어진 렐루 네트워크를 함수 f : R -> R로 근사시켜보자
입력 :
x (1, )
입력 :
y (1, )
1층 가중치 : w (3,1)
1층 편향 : b (3, )
2층 가중치 : u (1,3)
2층 편향 : p (1, )
h1 = max(0, w1 * x + b1)
h2 = max(0, w2 * x + b2)
h3 = max(0, w3 * x + b3)
y = u1 * h1 + u2 * h2 + u3 * h3 + p
▪ 하지만 여기에 네 번째 렐루 함수를 이용하면, s4부터 내려가는것을 상쇄시켜 우리가 아는 범프 함수가 만들어 집니다.
▪ 지금 보고 있는 4개의 렐루 함수 조합이 신경망에서 4개의 은닉층 유닛으로 사용되고 있는것입니다. 그리고 이 범프 함수의 위
치, 기울기, 높이 같은 것들은 1, 2층에 있는 가중치들로 조절할수 있겠습니다.
보편적 근사화 Universal Approximation
4개의 은닉층 유닛으로
범프 함수를 만들 수 있습니다.
13. y = u1 * max(0, w1 * x + b1)
+ u2 * max(0, w2 * x + b2)
+ u3 * max(0, w3 * x + b3)
+ p
예시 : 두 층으로 이루어진 렐루 네트워크를 함수 f : R -> R로 근사시켜보자
입력 :
x (1, )
입력 :
y (1, )
1층 가중치 : w (3,1)
1층 편향 : b (3, )
2층 가중치 : u (1,3)
2층 편향 : p (1, )
h1 = max(0, w1 * x + b1)
h2 = max(0, w2 * x + b2)
h3 = max(0, w3 * x + b3)
y = u1 * h1 + u2 * h2 + u3 * h3 + p
▪ 이제 신경망이 은닉 유닛이 4개가 아닌 8개, 12개, 16를 가졌다고 하고, 이 네 유닛들을 각 그룹으로 나눠 범프 함수를 계산한다
고 해봅시다. 그러면, 오른쪽과 같이 서로 다른 위치와 높이를 가진 범프들을 조합한 결과를 얻을 수가 있겠습니다.
보편적 근사화 Universal Approximation
4개의 은닉층 유닛으로
범프 함수를 만들 수 있습니다.
4K개의 은닉 유닛들로 K개의
범프들을 합칠수 있습니다.
14. y = u1 * max(0, w1 * x + b1)
+ u2 * max(0, w2 * x + b2)
+ u3 * max(0, w3 * x + b3)
+ p
예시 : 두 층으로 이루어진 렐루 네트워크를 함수 f : R -> R로 근사시켜보자
입력 :
x (1, )
입력 :
y (1, )
1층 가중치 : w (3,1)
1층 편향 : b (3, )
2층 가중치 : u (1,3)
2층 편향 : p (1, )
h1 = max(0, w1 * x + b1)
h2 = max(0, w2 * x + b2)
h3 = max(0, w3 * x + b3)
y = u1 * h1 + u2 * h2 + u3 * h3 + p
▪ 그리고 이 범프들의 위치를 자유롭게 조정할 수 있다면, 모든 타입의 연속함수들을 범프함수로 근사시켜 구할수가 있겠습니다.
그리고, 이렇게 근사시킨 함수가 더 정확해지려면 범프 함수 사이 갭을 줄여야 되겠죠. 아니면 범프 사이에 범프를 더 많이 둠으
로서 더 정확한 근사화를 할수 있어요.
▪ 신경망에서는 이런 방식이 자주 사용되고 있으며, 이런 2층 신경망이 어떤 종류의 연속함수를 적당한 정확도로 계산을 하며 범
프 함수를 이용한 근사화라는 개념을 이해하는 데 충분히 좋다고 할수 있을거 같아요. 정밀도를 더 높이고 싶다면, 은닉층이 더
많은 유닛들을 가져야 할 겁니다.
보편적 근사화 Universal Approximation
4개의 은닉층 유닛으로
범프 함수를 만들 수 있습니다.
4K개의 은닉 유닛들로 K개의
범프들을 합칠수 있습니다.
범프로 함수를 근사하자!
15. y = u1 * max(0, w1 * x + b1)
+ u2 * max(0, w2 * x + b2)
+ u3 * max(0, w3 * x + b3)
+ p
예시 : 두 층으로 이루어진 렐루 네트워크를 함수 f : R -> R로 근사시켜보자
입력 :
x (1, )
입력 :
y (1, )
1층 가중치 : w (3,1)
1층 편향 : b (3, )
2층 가중치 : u (1,3)
2층 편향 : p (1, )
h1 = max(0, w1 * x + b1)
h2 = max(0, w2 * x + b2)
h3 = max(0, w3 * x + b3)
y = u1 * h1 + u2 * h2 + u3 * h3 + p
▪ 여기에 보편적 근사화에 대해 이것을 어떻게 증명하는지, 범프 함수의 갭을 얼마나 해야하는지, 비선형성은 어떻게 해야하는지,
고차원에서 어떻게 다루는지에 대해 질문들이 있을수도 있겠지만, 지금 설명하기에는 시간이 부족하고 마이클 닐센 Michael
nielsen의 딥러닝 책 4강을 참고하시기 바랍니다.
보편적 근사화 Universal Approximation
범프 함수를 이용한 근사화에 대한 질문 사항들
- 범프 사이에 갭을 얼마나 둬야해요?
- 비선형성은 어떻게 대처하죠?
- 고차원의 함수인 경우 어떡해요?
=> 닐센의 딥러닝 책 4장 참고하세요.
16. y = u1 * max(0, w1 * x + b1)
+ u2 * max(0, w2 * x + b2)
+ u3 * max(0, w3 * x + b3)
+ p
예시 : 두 층으로 이루어진 렐루 네트워크를 함수 f : R -> R로 근사시켜보자
입력 :
x (1, )
입력 :
y (1, )
1층 가중치 : w (3,1)
1층 편향 : b (3, )
2층 가중치 : u (1,3)
2층 편향 : p (1, )
h1 = max(0, w1 * x + b1)
h2 = max(0, w2 * x + b2)
h3 = max(0, w3 * x + b3)
y = u1 * h1 + u2 * h2 + u3 * h3 + p
▪ 여기에 보편적 근사화에 대해 이것을 어떻게 증명하는지, 범프 함수의 갭을 얼마나 해야하는지, 비선형성은 어떻게 해야하는지,
고차원에서 어떻게 다루는지에 대해 질문들이 있을수도 있겠지만, 지금 설명하기에는 시간이 부족하고 마이클 닐센 Michael
nielsen의 딥러닝 책 4강을 참고하시기 바랍니다.
▪ 아무튼 지금까지 신경망의 기초에 대해서 보았는데, 보편적 근사화를 통해 신경망이 어떤 종류의 연속 함수들 간에 상관없으며,
명확하고, 선형 분류기보다 사용하기 좋다는 것을 배웠습니다. 하지만 주의해야할점은 보편적 근사화는 신경망이 다양한 함수에
도 활용가능하다는 잠재적인 능력과 개념을 보여주기 위한 것이라 실제 적용하기 힘든 점이 많으니 신경 필요는 없습니다.
보편적 근사화 Universal Approximation
범프 함수를 이용한 근사화에 대한 질문 사항들
- 범프 사이에 갭을 얼마나 둬야해요?
- 비선형성은 어떻게 대처하죠?
- 고차원의 함수인 경우 어떡해요?
=> 닐센의 딥러닝 책 4장 참고하세요.
17. y = u1 * max(0, w1 * x + b1)
+ u2 * max(0, w2 * x + b2)
+ u3 * max(0, w3 * x + b3)
+ p
예시 : 두 층으로 이루어진 렐루 네트워크를 함수 f : R -> R로 근사시켜보자
입력 :
x (1, )
입력 :
y (1, )
1층 가중치 : w (3,1)
1층 편향 : b (3, )
2층 가중치 : u (1,3)
2층 편향 : p (1, )
h1 = max(0, w1 * x + b1)
h2 = max(0, w2 * x + b2)
h3 = max(0, w3 * x + b3)
y = u1 * h1 + u2 * h2 + u3 * h3 + p
▪ 보편적 근사화는 신경망의 계산을 매우 복잡하게 하는 가중치가 존재하는지 여부만을 알려줍니다. 하지만 어떻게 적당한 함수
로 학습을 해서 가중치를 갖는지 같이 대답되지 않은 질문들이 많이 있으나 보편적 근사화는 어떻게 가중치가 정해지는지 적절
하게 학습하려면 얼마나 많은 데이터가 필요하는지 같은 것들을 알려주지는 않습니다.
▪ 그리고 보편적 근사화를썻으니 신경망이 최고의 모델이라고 생각해서는 안됩니다. 우리는 2강에서 K 최근접 이웃을 봤었는데,
이 방법에도 보편적으로 근사화 시키는 속성을 가지고 있었습니다. 신경망에서 보편적 근사화는 마법 같았지만, 최근접 이웃에서
는 그렇게 효과적이지는 않습니다.
보편적 근사화 Universal Approximation
범프 함수를 이용한 근사화에 대한 질문 사항들
- 범프 사이에 갭을 얼마나 둬야해요?
- 비선형성은 어떻게 대처하죠?
- 고차원의 함수인 경우 어떡해요?
=> 닐센의 딥러닝 책 4장 참고하세요.
18. y = u1 * max(0, w1 * x + b1)
+ u2 * max(0, w2 * x + b2)
+ u3 * max(0, w3 * x + b3)
+ p
예시 : 두 층으로 이루어진 렐루 네트워크를 함수 f : R -> R로 근사시켜보자
입력 :
x (1, )
입력 :
y (1, )
1층 가중치 : w (3,1)
1층 편향 : b (3, )
2층 가중치 : u (1,3)
2층 편향 : p (1, )
h1 = max(0, w1 * x + b1)
h2 = max(0, w2 * x + b2)
h3 = max(0, w3 * x + b3)
y = u1 * h1 + u2 * h2 + u3 * h3 + p
▪ 지금까지 왜 신경망이 좋은지, 선형 모델에 비해 유연한지 많이 이야기를 했지만 최적화의 관점에서는 많이 살펴보지는 않았습
니다. 일단 보편적 근사화는 다양한 함수들로 표현할수 있는 가중치 값들이 존재한다는 사실을 알려주나, 어떻게 가중치를 찾아
내는지는 알려주지를 못합니다.
▪ 그럼 질문으로 어떻게 신경망이나 다른 머신 러닝 모델이 최적해에 수렴할수 있게되는지 궁금하실 겁니다. 최적화와 수렴에 대
해 이야기하기 위해 사용하는 수학적 도구로 컨벡스 함수, 볼록 함수 convex function이 있습니다.
범프 함수를 이용한 근사화에 대한 질문 사항들
- 범프 사이에 갭을 얼마나 둬야해요?
- 비선형성은 어떻게 대처하죠?
- 고차원의 함수인 경우 어떡해요?
=> 닐센의 딥러닝 책 4장 참고하세요.
컨벡스 함수 Convex Function(볼록 함수?)
19. ▪ 컨벡스 함수는 입력 벡터를 주었을때 단일 스칼라 값을 반환해주는 함수로, 비용 함수와 신경망 기반 시스템같은 것들이 있습
니다. 이런 모델들은 입력을 이용해서 지정한 가중치와 연산을해서 스칼라 값인 비용으로 출력이 나왔었죠. 여기서 비용은 학습
한 가중치 행렬이 얼마나 올바른지를 나타냈었습니다.
컨벡스 함수 Convex Function(볼록 함수?)
20. ▪ 이제 컨벡스라고 부르는 함수는 특정한 부등식 제약조건을 만족하는 함수로 시각적으로 보면 이해하기 더 쉬울것 같아요. 만약
위와 같은 부등식 조건과 f(x) = x^2인 예시를 사용해서 봅시다. 입력 x1, x2이 주어 질 때, 이 두 입력의 선형 결합을 입력으로 준
결과가 좌측 항이되며 우측의 항보다 작아야 합니다.
컨벡스 함수 Convex Function(볼록 함수?)
21. ▪ 이 우측 항은 점 x1, x2 사이의 함수 f에 대한 곡선을 나타냅니다. 이 할선은 x1에서의 함수값과 x2에서의 함수 값을 선형 결합
의 형태로 구하게 되요. 그래서 컨백스 하다는 것은 입력 공간에서 두 점이 있을때, 두 점 사이의 할선보다 함수가 작다는 것을 의
미합니다.
▪ 이러한 컨벡스의 기하학적 특성을 이해하면 위의 이차식 quadratic function이 컨벡스 하다는것을 알수 있습니다. 입력 공간에
서 어느 두 지점을 정하던 간에 두 점의 할선보다 함수가 아래에 있기 때문이거든요.
컨벡스 함수 Convex Function(볼록 함수?)
22. ▪ 이제 이 식을 시각적으로 증명할 수 있었지만 cos(x) 함수의 경우 컨벡스 하지는 않습니다. 위를 보시다 시피 법선을 찾긴 했지
만 곡선이 법선의 위에 도 있고, 아래에도 있거든요. 그래서 이 함수는 컨벡스라고 할수는 없겠습니다.
컨벡스 함수 Convex Function(볼록 함수?)
23. ▪ 컨벡스에 대해 다차원 함수로 더 일반화해서 생각해보면, 컨벡스 함수는 고차원 아날로그, 볼 형태의 고차원 일반화 함수라고
할수 있습니다. 이 함수는 볼처럼 생겻기도하고, 어느 점이건 간에 법선이 함수 보다 크기 때문입니다. 아무튼 컨백스 함수는 아
름답고 놀라운 수학적 성질을 가졌다고 할수 있겠습니다.
컨벡스 함수 Convex Function(볼록 함수?)
이해하기 : 컨백스 함수는
(다차원 적으로) 그릇같다.
24. ▪ 이에 대해서 더 자세히 알고 싶다면 IOE의 강의나 math 663강의를 참고하시기 바랍니다. 주의해야할 점은 컨벡스 함수나 컨벡
스 최적화에 대한 모든것을 배우려고 하지 마세요. 이 수업에서의 목표는 컨백스 함수는 그릇 처럼 생겻고, 최적화하기에 좋다 정
도만 알면 되거든요.
컨벡스 함수 Convex Function(볼록 함수?)
이해하기 : 컨백스 함수는
(다차원 적으로) 그릇같다.
컨벡스 함수는 최적화하기 쉽다.
전역적 극소점에 수렴함을 보장한다!
25. ▪ 지금까지 선형 분류기, 선형 모델에 대해 많이 이야기한 건 최적화 때문이며, 우리의 데이터에 가장 적합한 선형 모델을 찾기 위
해 최적화로 학습시켯기 때문입니다. 소프트 맥스나 SVM아니면 선형 회귀 같은 문제들에 상관없이 이런 모델들을 학습하는 최
적화 문제는 컨백스 최적화 문제라고 할수 있으며, 이는 선형 모델은 학습 과정에서 수렴성을 보장한다고 할수 있습니다. 이러한
이유로 사람들이 신경망 모델보다 선형 모델을 선호하기도 합니다.
컨벡스 함수 Convex Function(볼록 함수?)
이해하기 : 컨백스 함수는
(다차원 적으로) 그릇같다.
컨벡스 함수는 최적화하기 쉽다.
전역적 극소점에 수렴함을 보장한다!
선형 분류기 최적화도
컨벡스 함수다!
26. ▪ 하지만 신경망 기반 시스템에서는 수렴성을 보장할수 없다보니 사용하는 방법은 신경망의 비용 표면을 잘게 잘라서, 의미있는
것을 찾아나가야 합니다. 예를 들어 5층 신경망을 만들었다고 해봅시다. 그리고 그 신경망의 1층의 한 가중치 요소를 골랐는데,
여기서 x축은 이 원소의 가중치 값이고, y축은 이 원소가 변할때 비용의 변화를 보여주고 있습니다.
▪ 그래서 고차원 신경망을 최적화할때 비용 표면에 대해 어떻게 생각해야할까요?? 신경망이 고차원인 경우 비용 표면을 시각화
할수 없습니다. 하지만 요기서는 매우 고차원인 비용 표면을 1차원으로 나누어 보여주고 있고, 우리들은 비용 표면의 비용 일부
를 볼수 있게 되었습니다. 이렇게 보니 컨백스, 볼 처럼 생겼죠.
컨벡스 함수 Convex Function(볼록 함수?)
이해하기 : 컨백스 함수는
(다차원 적으로) 그릇같다.
컨벡스 함수는 최적화하기 쉽다.
전역적 극소점에 수렴함을 보장한다!
인공 신경망의 비용이
컨벡스 처럼 보인다
27. ▪ 어떤 경우에는 비용 표면으로부터 잘라낸 일부분이 컨백스가 아닌 경우도 있습니다.
컨벡스 함수 Convex Function(볼록 함수?)
이해하기 : 컨백스 함수는
(다차원 적으로) 그릇같다.
컨벡스 함수는 최적화하기 쉽다.
전역적 극소점에 수렴함을 보장한다!
컨백스가 아니야
28. ▪ 위의 경우는 그라디언트 기반, 기울기 기반 학습에 적합하지 않다고 할수 있는데, 경사 하강법으로 비용 표면을 최적화하다가
사이의 계곡에 빠져버릴수도 있거든요.
▪ 심층 신경망을 학습할때 이런 수많은 비용 표면들이 존재하다보니 신경망은 비 컨백스 최적화 방법을 사용하여야 합니다. 이런
지역적 극소점에 빠지는걸 방지하려면요. 이론적으로 수렴성을 보장해주는게 없다보니, 신경망 훈련할때 어떻게 최적화를 해나
가야 하는지에 대한 연구가 활발하게 이뤄지고 있습니다.
컨벡스 함수 Convex Function(볼록 함수?)
이해하기 : 컨백스 함수는
(다차원 적으로) 그릇같다.
컨벡스 함수는 최적화하기 쉽다.
전역적 극소점에 수렴함을 보장한다!
컨백스가 아니야