Spark machine learning & deep learninghoondong kim
Spark Machine Learning and Deep Learning Deep Dive.
Scenarios that use Spark hybrid with other data analytics tools (MS R on Spark, Tensorflow(keras) with Spark, Scikit-learn with Spark, etc)
Zeppelin Notebook:
https://github.com/uosdmlab/nsmc-zeppelin-notebook
네이버 영화 리뷰 데이터셋에 Word2Vec, sentiment classification을 적용해봅니다.
2017년 6월 27일 (화) "Spark Day 2017"에서 발표되었습니다.
Spark machine learning & deep learninghoondong kim
Spark Machine Learning and Deep Learning Deep Dive.
Scenarios that use Spark hybrid with other data analytics tools (MS R on Spark, Tensorflow(keras) with Spark, Scikit-learn with Spark, etc)
Zeppelin Notebook:
https://github.com/uosdmlab/nsmc-zeppelin-notebook
네이버 영화 리뷰 데이터셋에 Word2Vec, sentiment classification을 적용해봅니다.
2017년 6월 27일 (화) "Spark Day 2017"에서 발표되었습니다.
Auto Scalable 한 Deep Learning Production 을 위한 AI Serving Infra 구성 및 AI DevOps...hoondong kim
[Tensorflow-KR Offline 세미나 발표자료]
Auto Scalable 한 Deep Learning Production 을 위한 AI Serving Infra 구성 및 AI DevOps Cycle 구성 방법론. (Azure Docker PaaS 위에서 1만 TPS Tensorflow Inference Serving 방법론 공유)
- E-commerce BigData Scale AI Journey
- BigData Scale Deep Learning Production System Use Case
- Deep Learning, Cloud PaaS, Microservices, DevOps, etc.
- E-Commerce AI Production System Strategy
100% Serverless big data scale production Deep Learning Systemhoondong kim
- BigData Sale Deep Learning Training System (with GPU Docker PaaS on Azure Batch AI)
- Deep Learning Serving Layer (with Auto Scale Out Mode on Web App for Linux Docker)
- BigDL, Keras, Tensorlfow, Horovod, TensorflowOnAzure
Big Data Platform Field Case in MelOn (in Korean)
- Presented by Byeong-hwa Yoon, engineer manager at Loen Entertainment
- at Gruter TECHDAY 2014 Oct. 29 Seoul, Korea
Auto Scalable 한 Deep Learning Production 을 위한 AI Serving Infra 구성 및 AI DevOps...hoondong kim
[Tensorflow-KR Offline 세미나 발표자료]
Auto Scalable 한 Deep Learning Production 을 위한 AI Serving Infra 구성 및 AI DevOps Cycle 구성 방법론. (Azure Docker PaaS 위에서 1만 TPS Tensorflow Inference Serving 방법론 공유)
- E-commerce BigData Scale AI Journey
- BigData Scale Deep Learning Production System Use Case
- Deep Learning, Cloud PaaS, Microservices, DevOps, etc.
- E-Commerce AI Production System Strategy
100% Serverless big data scale production Deep Learning Systemhoondong kim
- BigData Sale Deep Learning Training System (with GPU Docker PaaS on Azure Batch AI)
- Deep Learning Serving Layer (with Auto Scale Out Mode on Web App for Linux Docker)
- BigDL, Keras, Tensorlfow, Horovod, TensorflowOnAzure
Big Data Platform Field Case in MelOn (in Korean)
- Presented by Byeong-hwa Yoon, engineer manager at Loen Entertainment
- at Gruter TECHDAY 2014 Oct. 29 Seoul, Korea
Escape Game is the most attractive game. Beat The Clock Invited you to play and enjoy escape game with your loving one. Enjoyably you have to collect all the hidden clues with in 1 hour and bash the escape room door.
Copa America 2016 fixture. All match schedule including venue name. Detail description of Copa America 2016. Including the link where you can watch match highlights, goals and all updates of Copa America 2016.
A comprehensive flour mills management system. It provides you latest picture of your flour mill. All stocks raw and finished goods are available at anytime. production and sales after production are related in a way that stocks are always up to date. You can view and print reports of various types using drop down facility.
Following are some of main features available in the software system.
1. Secure password driven access to software system
2. Govt. & Private wheat purchase record
3. Party payable details
4. Party ledgers in detail
5. Bags record with types and classes
6. Stock movement from one godawn to another or factory
7. Grinding Details & production records
8. Credit and Cash Sales Record
9. Purchase & Sales of Bags
10. Cash Payment & Cash Receipt Entries ( Cash Book )
11. Wheat and Products stock report
12. Income & Expense Analysis
13. Party wise ledger details
14. Historical Stock Situation
15. Many more reports and facilities for top Management
The Data tech for AI based innovation(기업의 AI기반 혁신을 지원하는 데이터 기술)SANG WON PARK
2020년 데이터산업진흥원에서 발표한 자료를 일부 편집하여 공유함.
2020년 당시에 Data Platform에서 AI lifecycle를 효율적으로 지원하는 platform을 적극적으로 검토 및 설계하는 작업을 진행하였고, 이 때 검토 및 활용했던 기술들을 기업 관점에서 필요한 내용을 기준으로 정리하였다.
기업들은 전통적인 방식으로의 혁신에 한계를 체감하고 있으며, 최근 AI기반으로 성공적인 혁신(비즈니스 강화, 새로운 비즈니스로 전환 등)에 성공한 기업들을 빠르게 벤치마크 하고 있다.
이렇게 AI 기반으로 기업을 혁신하는 것은 고도화된 AI 모델의 도입으로 해결되지 않으며, 수많은 기술들의 최적화된 조합 및 활용이 필요하다.
이 자료에서는 그 중 AI모델에 핵심적인 데이터를 적시에, 고품질의 형태로, 빠르고 안정적으로 제공할 수 기술 트렌드를 소개한다.
전체 내용은
- AI기반 혁신이란?
- 혁신을 위해서는 어떤 점이 어려운가?
- 고품질 데이터 확보 기술
- 빠르게 AI 모델을 학습하는 기술
- 적시에 다양한 AI 모델을 비즈니스에 적용하는 기술
2020년 기준으로 작성된 자료라, 일부 기술 트렌드가 반영되지 않을 수 있으나 아직까지 많은 기업들이 고민하고 해결하고자 하는 영역이라 참고할 수 있을 것 같다.
이 내용을 기준으로 발표한 영상 링크 : https://www.youtube.com/watch?v=OVm4-uk59ZA
빅데이터 개념 부터 시작해서 빅데이터 분석 플랫폼의 출현(hadoop)과 스파크의 등장배경까지 풀어서 작성된 spark 소개 자료 입니다.
스파크는 RDD에 대한 개념과 spark SQL 라이브러리에 대한 자료가 조금 자세히 설명 되어있습니다. (텅스텐엔진, 카탈리스트 옵티마이져에 대한 간략한 설명이 있습니다.)
마지막에는 간단한 설치 및 interactive 분석 실습자료가 포함되어 있습니다.
원본 ppt 를 공개해 두었으니 언제 어디서든 필요에 따라 변형하여 사용하시되 출처만 잘 남겨주시면 감사드리겠습니다.
다른 슬라이드나, 블로그에서 사용된 그림과 참고한 자료들은 작게 출처를 표시해두었는데, 본 ppt의 초기버전을 작성하면서 찾았던 일부 자료들은 출처가 불분명한 상태입니다. 자료 출처를 알려주시면 반영하여 수정해 두도록하겠습니다. (제보 부탁드립니다!)
Backend.AI (https://backend.ai)는 클라우드 및 온-프레미스 환경에서 여러 사용자가 안전하고 효율적으로 컴퓨팅 자원을 공유할 수 있는 머신러닝에 특화된 인프라 관리 프레임워크입니다. 현재 널리 사용되고 있는 오픈소스 기술인 OpenStack, Kubernetes 등과 비교하여 어떤 특징과 차이점이 있는지 소개하고, 프레임워크의 구조와 기반 기술 및 응용 사례를 데모와 함께 소개합니다.
3. Algorithm Trading?
• 알고리즘 트레이딩은 수학적 계산과 IT 시스템을 이
용해 트레이딩을 하는 것으로 시스템 트레이딩,
Algo Trading 혹은 Blackbox 트레이딩이라고
한다.
• 알고리즘 트레이딩은 투자은행, 연기금, 헤지펀드,
증권회사등 많은 곳에서 사용되고 있으며, 최근 몇
년사이에는 수학적지식과 IT지식을 가진 개인들도
많이 참여하고 있다.
9. Powered By Celery & RSync
Celery를 이용한 작업의 분산
그리고
Rsync를 이용한 결과 파일의 업데이트
Celery = Distributed Async Task Queue
긴 실행시간을 필요로 하는 작업
백그라운드로 실행할 필요가 있는 작업
주기적으로 실행할 필요가 있는 작업
13. First Trial의 가벼움
ML Slave
ML Slave
ML Slave
직접 할당
• 리소스관리의 어려움
• 노드 확장성의 문제
• 아키텍쳐의 문제
• 생각보다 까다로운 Celery
• 데이터 공유 문제
미친듯이 많은 모델들을 실시간으로 생성할 수 있는 뭔가 보다 세련된 방법이 필요하다!!!
SSH Execution?
14. 내가 필요한 것!
Data #1
Data #2
Data #N
Data Store
Model #1
Model #2
Model #N
Prediction
학습에서 최종모델 배포까지 1-2시간이내 완료!!!
aggregation training deployment
15. 좀 더 구체적으로 표현하면
• 다양한 종류의 데이터 소스 사용
• 실시간 데이터 분석 및 학습
• 대용량 데이터 처리 기능
• 학습종료된 모델의 실시간 배치
• 머신러닝 노드 클러스터 확장
• 보다 효율적인 리소스 활용
• 머신러닝 클러스터 관리의 편리함
• Docker 연동
• 기타등등
17. Apache Spark
• Speed
• Up to 100x faster than hadoop
• Ease of Use
• Python, Scala, Java, R
• Generality
• Combine SQL, streaming, analytics
• Runs Everywhere
• Mesos, Hadoop, Standalone
• HDFS, Cassandra, Hbase, S3
Lightning fast cluster computing
Fast and scalable general data processing framework
18. Apache Mesos
• Linear Scalability
• Two Level Scheduling
• High Availability
• APIs
• Pluggable Isolation
• Resource Management
• Supports Spark, Hadoop, Kafaa, ElasticSearch
A Distributed System Kernel
abstracts CPU, memory, storage, and other compute resources away from machines,
enabling fault-tolerant and elastic distributed systems
19. Running Spark in Mesos
Client Mode Cluster Mode
• 명령을 실행하는 머신에서 직접 실행
• spark-env.sh에 설정 필요
• MESOS_NATIVE_JAVA_LIBRARY
• SPARK_EXECUTOR_URI
• Mesos에 의해 태스크가 실행됨
• MesosClusterDispatcher 를 실행시켜야 함
• Spark-submit 을 이용해 실행
• 실행파일을 클러스터에서 액세스 가능하도록 설정
20. Mesos Run Modes
Fine-grained Coarse-grained
• 메모리는 정적으로 할당받지만 CPU는 공유함
• 다른 태스크의 상황에 따라 성능이 변화됨
• conf.set("spark.mesos.coarse", "false")
• 메모리와 CPU를 모두 정적으로 할당받음
• 아래의 값들에 의해 할당됨
• spark.executor.memory
spark.executor.cores
• Spark.cores.max/spark.executor.cores
• conf.set("spark.mesos.coarse", ”true")
21. Python Library Management
Egg or Zip Configuration Tool
• Python 필요한 라이브러리를 egg or zip 파일로 만
들어 pyFiles에 추가해 배포할 수 있음
• 실행하려고 할 때마다 매번 라이브러리 배포
• Ansible, puppet, chef와 같은 도구를 이용해 필요
한 라이브러리를 설치할 수 있음
• 태스크 실행시 라이브러리는 포함하지 않음
22. Hadoop이 필요할까?
• 머신러닝만 생각하면 굳이 필요는 없었지
만 …
• Distributed File System
• Disaster Recovery
• Hadoop Ecosystem
23. spark-submit, 보다 세련된 뭔가가 필요해
./bin/spark-submit --class SimpleApp --
master mesos://dev-goose:7077 --deploy-
mode cluster simple-project_2.10-1.0.jar
REST API based Job Server
24. Spark Job Server
• "Spark as a Service": Simple REST interface (including HTTPS) for all aspects of
job, context management
• Support for Spark SQL, Hive, Streaming Contexts/jobs and custom job contexts!
See Contexts.
• LDAP Auth support via Apache Shiro integration
• Works with Standalone Spark as well as Mesos and yarn-client
• Named Objects (such as RDDs or DataFrames) to cache and retrieve RDDs or
DataFrames by name, improving object sharing and reuse among jobs.
https://github.com/spark-jobserver/spark-jobserver
25. 현재의 머신러닝 클러스터
ML Slave 1
ML Slave 2
ML Slave 3
ML Slave 4
ML MasterSpark Job Server
Hadoop
26. Before vs After
• 노드추가가 편해졌음
• Mesos Slave, Hadoop 설정만으로 OK
• Streaming 처리가 가능해진 환경
• Online Learning을 시도할 수 있게 되었음
• Dataframe이 RDD보다 성능이 더욱 좋음.
• Celery보다는 안정적인 환경
• 극적인 시간단축의 핵심은 머신러닝 알고리즘
• Tensorflow를 Spark에서
• 대규모의 데이터를 이용한 학습이 가능해짐