Wednesday, November 20, 2013

Episode 30: FPGAs


Download

Introduction

Patrick's hiking extravaganza.  Jason's move across town.
News
Book of the Show
Tool of the Show

FPGA

History
  • ROM as a PLD
  • CPLD
  • FPGA
Programming
  • Schematic
  • Hardware Definition Language (VHDL & Verilog)
  • RTL vs Structured
  • Interacting with the processor
    • Serial connection
    • Memory Mapped
Pros
  • Parallelism (i/o)
  • Speed
Cons
  • Relatively Difficult to program
  • Testing can be hard
  • Lack of good tool
  • Expensive tools
Features
  • Embedded Cores
  • Soft Cores
  • Reprogramming on the fly

Wednesday, September 4, 2013

Episode 29: CUDA and OpenCL


Download

Introduction

http://www.origamitessellations.com/
News
Book of the Show
Tool of the Show

CUDA and OpenCL

History
  • GPU: Graphics Processing Unit
    • Vertex: A point in a triangle (poly)
      • Vertex Shader: Transforms properties of a vertex
    • Fragment: A portion of a pixel
      • Fragment Shader: Sets the color & alpha of a pixel for a poly.
    • GPUs are optimized for performing the same operation on many vertices / fragments.
  • GPGPU: General-Purpose Graphics Processing Unit
    • Transform input data to images
    • Turn off any special effects (fog, lighting, etc.)
    • Render exactly one frame
    • Read output data from screen
Common concepts
  • Both CUDA and OpenCL Relieve the developer from having to know about vertex/fragment shaders & graphics processing.
    • Data is organized in n-D arrays
    • Can specify read-only (write-once), write-only (read-never), or read-write.
    • Can copy data to/from GPU with a familiar interface
  • High latency, but can pipeline operations
  • The GPU is organized into warps (groups of threads).  Each thread in a warp must either perform the same operation or do nothing per cycle. (branching is bad)
  • Integer operations are slow, floating point is fast
  • Debugging can be a nightmare (but improving)
CUDA
  • Write .h and .cu files (subset of C)
  • Compile with nvidia compiler, link with your C++ binary.
  • NVIDIA Libraries:
    • cuBLAS (CUDA Basic Linear Algebra Subprograms)
    • cuFFT (CUDA Fast Fourier Transform)
  • Language bindings for many languages (Python, Java, Lua, etc.)
OpenCL
  • A standard (like OpenGL) that has CPU and GPU implementations
  • Easy to debug on the CPU before running on the GPU
  • Not limited to NVIDIA graphics cards (good for distribution)

Thursday, June 13, 2013

Episode 28: Applied Artificial Intelligence


Download

Feedback
  • 107 Reviews on iTunes
  • America's Test Kitchen
  • Picking a Programming Language
Tool of the Show
Book of the Show

Applied Artificial Intelligence

Common Terms
  • Objective Function
  • Features
  • Under/Over Fitting
  • Classification / Regression / Control
Methods
  • Supervised (Learn a function from residuals)
    • Gradient-Descent
    • Perceptron
    • Back-Propagation (Non-Linear)
  • Reinforcement Learning (Estimating value from reward)
    • Minimax, Monte Carlo Tree Search (MCTS)
    • Temporal Difference Learning
    • Genetic Algorithms
    • NEAT
  • Unsupervised (Clustering & Dimensionality Reduction)
    • K-Means
    • PCA
    • Neural Gas
Challenges
  • Making an objective function
  • Training-Serving Skew
  • Modeling
    • Linearizing
    • Feature-Extraction & Discretization
    • Kernels
  • Measuring Performance

Friday, May 31, 2013

Episode 27: Artificial Intelligence Theory


Download

News
Tool of the Show
Book of the Show


Theoretical Artificial Intelligence

History
  • The Turk 1770
  • Turing Test, Three Laws of Robotics(1942)
  • First neural net: 1951
  • Arthur Samuel’s Checkers AI: ‘51
  • Golden Age (‘56 - ‘74)
  • AI Winter (74-80)
  • Renaissance (1990+)
  • Deep Blue vs kasparov 1996
What is AI?
  • "Real" Intelligence versus Artificial Intelligence
  • Common-Sense Knowledge
  • Goals: Deducting, Reasoning, Problem Solving
Challenges
  • “Strong AI” (General AI): Artificial Intelligence that meets or exceeds human intelligence at every level.
  • Combinatorial explosion in planning
  • Knowledge representation
  • The frame problem
AI Projects

Episode 25: Unit Testing


Download

News
Tool of the Show
Book of the Show


Unit Testing

History
  • 1956 “The Debugging Period”
    • Testing associated with debugging
  • 1957 - 1978 “Demonstration Period”
    • Show software satisfies requirements
  • 1979 - 1982 “Destruction Oriented Period”
    • Testing should find errors
  • 1983 - 1987 “Evaluation Oriented Period”
    • Testing to measure quality
  • 1988+ “Prevention-Oriented”
    • Detect and prevent faults
Features
  • Prove correctness
  • Mocking
  • Code Coverage (Statement  and branch)
Strengths
  • Establish a contract for the code
  • Make sure there is no unreachable code
  • Force writing testable code
  • Can serve as programmatic documentation
Weaknesses
  • Time consuming
  • Establish constraints that may not be valid
  • False sense of security
Tools
  • Java
    • JUnit
    • EasyMock, Mockito
  • C++
    • cpptest
    • gmock

Tuesday, March 26, 2013

Episode 26: Image Processing


Download

News
Tool of the Show
  • Jason: Moon Reader Pro+ (Android)
  • Patrick: Spaceteam (iOS)
Book of the Show


Image Processing

Overview
  • Image Processing: Image in -> image out
  • Image Analysis: Image in -> Measurements out
  • Image Understanding: Image in -> High level description out
Features & Methods
  • Matrices
  • Binary Images
  • Image Convolution
  • Histograms
  • Feature Vector
  • Artificial Intelligence
  • Singular Value Decomposition
  • Neural Networks
Challenges
  • Amount of Data to Process
  • Limited Bit Depth
  • Noise
  • Orientations
  • Occlusion
Tools
  • PIL
  • OpenCv
  • MatLab
  • Photoshop / Gimp

Tuesday, January 29, 2013

Episode 24: JVM Languages (Jython, Clojure, Scala)


Download

News
Tool of the Show
Book of the Show


JVM Languages (Jython, Clojure, Scala)

Strengths
  • Cross-Platform
  • Access to java libraries (especially UI)
  • Can sit on top of Hadoop
Weaknesses
  • Potentially slower
  • Require JVM tuning if memory usage is high