scaling charts with design and gpus leo meyerovich (@lmeyerov) ceo of graphistry.com | uc berkeley 1

36
Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1 Superconductor

Upload: harvey-preston

Post on 13-Jan-2016

216 views

Category:

Documents


2 download

TRANSCRIPT

Page 1: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

1

Scaling Charts with Design and GPUs

Leo Meyerovich (@LMeyerov)CEO of Graphistry.com | UC Berkeley

Superconductor

Page 2: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

2

Visibility

Page 3: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

3

Visibility through

design + speed

Page 4: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

4

Histogram of Voter Turnout by Town

0% 25%50%

75% 100%Voter

Turnout

# Towns

Most towns had ~40% people

vote

ballot box stuffing?

Page 5: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

5

Page 6: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

6

Opposition

Incumbent

Tiny square shows town size (area) and vote (color)

Page 7: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

7

Filter for townsw/ high turnout

Page 8: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

8

Tag suspicious with black

Page 9: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

9

Page 10: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

10

For visibility,

speed design

Page 11: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

11

allwork projecthobby projectmanagerfemale1 employee2-4 employees5-9 employees10-19 employees20-100 employees100-499 employees500 employees or moreis techmanager peerunder 2030+20-30

Problem: Plot 10+ Time Series Signals

Page 12: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

12

Design 200 Time Series Signals

100 s0 s 0 s

Page 13: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

13

Speed Pan/Zoom Interactions

38 s37 s 37 s

Page 14: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

14

CPU Bottlenecks: naïve and offline

TransformParse

LayoutRender

0ms 1600ms

real-time

is30ms

Page 15: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

15

Prep

Optimize Binary Data, Multicore Layout, GPU Render

LayoutRender

0ms 1600ms

• Real-time interaction• Stream from server

12MB+/s

Page 16: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

16

Graphs: Placing Nodes and Edges

Page 17: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

17

Direct Feedback on Settings

Page 18: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

18

Uber: Trip Start to End

Page 19: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

19

Direct Edge Placement: Overplotting

Page 20: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

20

Speed Design Edge Bundling

Page 21: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

21

Page 22: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

22

web

Page 23: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

23

Bare Metal in the Browser

Sequential

Multicore

GPU

5 X

4+ cores

1024 lanes

SIMD 4 lanes

Page 24: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

24

SUPERCONDUCTOR: Parallel JS Viz Engine

HTML dataCSS styling

JS script

Pixels

Parser

Selectors

Layout

Renderer

Java

Scrip

t VM

Renderer.GL

webpage

Layout.CL

Selectors.CL

GPU

datastyling

widgets

data viz

Compiler

Parser.js

BROWSERSUPERCONDUCTOR.js

Page 25: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

25

Leaf

Layout as Parallel Tree Traversals

w,h w,h

w,hw,h

w,hw,h x,y …

1. Works for all data sets2. Compiler: CSS Schedule

logical joins logical

spawns

Parallelism in each traversal!

Page 26: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

26

parallel for looplevel synchronous

GPU Traversals: Flat & Level-Synchronous

level 1

Tree

level n

whxy

Nodes in arrays

flat

Array per attribute

Compiler handles transform of code & data

Page 27: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

27

More Scalable DesignsImmens (Stanford) Nanocubes (AT&T) MapD (MIT)

Abstract Rendering (Continuum) Synerscope

Page 28: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

28

Page 29: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

29

Achieve data visibility throughhardware-accelerated designs

(and deploy on the web )

Page 30: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

30

Visualize Magnitudes More Data in the Browser

Leo Meyerovich (@LMeyerov)CEO of Graphistry.com | UC Berkeley

Graphistry

Page 31: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

31

Leaf

Layout as Parallel Tree Traversals

w,h w,h

w,hw,h

w,hw,h x,y …

1. Works for all data sets2. Compiler: CSS Schedule

logical joins logical

spawns

Parallelism in each traversal!

Page 32: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

32

parallel for looplevel synchronous

GPU Traversals: Flat & Level-Synchronous

level 1

Tree

level n

whxy

Nodes in arrays

flat

Array per attribute

Compiler handles transform of code & data

Page 33: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

33

L2: 1MB

RAM: 2GB

432

432256-way SIMTGPGPU core 1

4-way SIMD

L1d: 32KB

Today’s Supercomputer-in-a-Pocket

core 1

Pre

fetc

h

En

gin

e

1

Challenge: Parallelize Data

Visualization

Phone16-lane CPU

1024-lane GPU

Page 34: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

34

circ(…)

Problem: Dynamic Memory Allocation on GPU?

square(…) rect(…); …

line(…); …

rect(…); …

oval(…)

1.0 0.8 0.5 0.2 0 0.2

function circ (x,y,r) { buffer = new

Array(r * 10) for (i = 0; i < r * 10; i++)

buffer[i] = cos(i)}

dynamic

allocation

Page 35: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

35

Dynamic Allocation as SIMD Traversals

allocCirc(…) 4allocRect(…) 6

allocLine(…) 6

allocRect(…) 7

fillCirc(…)

fillRect(…)

fillLine(…)

fillRect(…)

1. Prefix sum for needed space2. Allocate buffers

3. Distribute offsets & compute4. Give OpenGL buffer

pointer

1.0 0.8 0.5 0.2 0 0.2

1.0 0.8 0.5 0.2

1.0 0.8 0.5 0.2 0 0.2

Page 36: Scaling Charts with Design and GPUs Leo Meyerovich (@LMeyerov) CEO of Graphistry.com | UC Berkeley 1

36

layout (4 passes)

rendering pass

TOTAL1

10

100

1,000

10,000Naïve JS (Chrome 26) GPU (Safari + WebCL 11/3) 24fps

Tim

e (

ms)

CPU vs. GPU for Election Treemap: 5 traversals over 100K nodes

WebCL: 30X

WebCL: 70X

COMBINED: 54X !