A language for auralizing data

Slides:



Advertisements
Similar presentations
Introduction to Maven 2.0 An open source build tool for Enterprise Java projects Mahen Goonewardene.
Advertisements

Video Game Design Lesson 1. Game Designer Person involved in the development of a video game Person involved in the development of a video game Usually.
WPSM Programming Language A simple language that transform simple data structure into complex xML format Wai Y. Wong Peter Chen Seema Gupta Miqdad Mohammed.
ESL - A language for Social Networks Team : Fantastic Four Ashwath Narsimhan – Project Manager Jyotsna Sebe – System Architect Shailesh Saroha – System.
Intro to C# Language Richard Della Tezra IS 373. What Is C#? C# is type-safe object-oriented language Enables developers to build a variety of secure.
1.3 Executing Programs. How is Computer Code Transformed into an Executable? Interpreters Compilers Hybrid systems.
ANTLR.
M1G Introduction to Programming 2 4. Enhancing a class:Room.
Conclusions What’s next? * Implementation of additional input formats * Additional vendor support: As vendors become more open with their APIs for accessing.
Chapter 1 Introduction Dr. Frank Lee. 1.1 Why Study Compiler? To write more efficient code in a high-level language To provide solid foundation in parsing.
Boardr The Racing Board Game Creation Language. Project Manager: Eric Leung Language and Tools Guru: Shensi Ding System Architect: Seong Jin Park System.
Unit-1 Introduction Prepared by: Prof. Harish I Rathod
CS 153: Concepts of Compiler Design August 26 Class Meeting Department of Computer Science San Jose State University Fall 2015 Instructor: Ron Mak
GarageBand Jessica Moidel Intro to Music Technology Final Presentation April 21, 2009.
Microsoft Visual Basic 2005 BASICS Lesson 1 A First Look at Microsoft Visual Basic.
1. 2 Preface In the time since the 1986 edition of this book, the world of compiler design has changed significantly 3.
Overview of Previous Lesson(s) Over View  A program must be translated into a form in which it can be executed by a computer.  The software systems.
. n COMPILERS n n AND n n INTERPRETERS. -Compilers nA compiler is a program thatt reads a program written in one language - the source language- and translates.
Dharmen Mehta (Project Manager) Nimai Buch (Language Guru) Yash Parikh (System Architect) Amol Joshi (System Integrator) Chaitanya Korgaonkar (Verifier.
Java Example Presentation of a Language. Background Conception: Java began as a language for embedded processors in consumer electronics, such as VCR,
FUNCTIONAL PROGRAMING AT WORK - HASKELL AND DOMAIN SPECIFIC LANGUAGES Dr. John Peterson Western State Colorado University.
A language for auralizing data. MOTIVATION  Visual input overload!  Automatic musical scoring.
ICS312 Introduction to Compilers Set 23. What is a Compiler? A compiler is software (a program) that translates a high-level programming language to machine.
MiniJava Compiler A multi-back-end JIT compiler of Java.
THRLL Programming Language Aimee Sanchez Neetha Sebastion Kapil Verma Hemanth Murthy Michael Seaman.
TypeScript for Alfresco and CMIS Steve Reiner CTO Integrated Semantics.
Introduction to Programming 1 1 2Introduction to Java.
Programming 2 Intro to Java Machine code Assembly languages Fortran Basic Pascal Scheme CC++ Java LISP Smalltalk Smalltalk-80.
Sung-Dong Kim, Dept. of Computer Engineering, Hansung University Java - Introduction.
Introduction to Algorithm. What is Algorithm? an algorithm is any well-defined computational procedure that takes some value, or set of values, as input.
Chapter 1 Coding Introduction.
Chapter 1. Introduction.
CS1316: Representing Structure and Behavior
Teaching Compiler Design
JavaScript/ App Lab Programming:
The architecture of the P416 compiler
Before You Begin Nahla Abuel-ola /WIT.
Introduction to Compiler Construction
Programming Language Hierarchy, Phases of a Java Program
Introduction to Visual Basic 2008 Programming
CS 153: Concepts of Compiler Design August 29 Class Meeting
Lecture 1: Introduction to JAVA
Objectives You should be able to describe: Interactive Keyboard Input
SOFTWARE DESIGN AND ARCHITECTURE
Brian Leonard ブライアン レオナルド
ICS103 Programming in C Lecture 1: Overview of Computers & Programming
CS101 Introduction to Computing Lecture 19 Programming Languages
CS1316: Representing Structure and Behavior
CE-105 Spring 2007 Engr. Faisal ur Rehman
Chapter 1: Introduction to Compiling (Cont.)
CS4101 Introduction to Embedded Systems Design and Implementation
Automated Automation of REST APIs
Sarah Kuria Beta Prototype
CMPE 152: Compiler Design ANTLR 4 and C++
Unit 20 Software Part 2.
CMPE 152: Compiler Design August 23 Class Meeting
Unit 20 Software Part 2.
Vocabulary Intro.
Introduction to JUnit IT323 – Software Engineering II
Presents: Rally To Java Conversion Suite
CS 1111 Introduction to Programming Spring 2019
Sound Processing with Pure Data
Introduction to Compiler Construction
CMPE 152: Compiler Design January 29 Class Meeting
CS1316: Representing Structure and Behavior
Java Code Review with CheckStyle
Games Development 2 Tools Programming
Introduction to Compiler Construction
IS 135 Business Programming
SSDT, Docker, and (Azure) DevOps
Presentation transcript:

A language for auralizing data I’m Peyton Sherwood, the Project manager of the Upbeat language team, and I’m here to give you an introduction to Upbeat

Motivation Visual input overload! Automatic musical scoring Do you have too much information clouding your visual field? Would you like to consume that information in a less confrontational way?

Upbeat A flexible language to auralize input data aur al iz a tion (n): 1. the act or process of interpreting in aural or musical terms 2. the process of converting data into music Previous attempts haven’t sounded great Upbeat is a flexible language to auralize input data. Auralization is a word that we invented which simply means to turn data into music. Nyquist, Max/MSP, Supercollider

Easy Coding, Better Music Easy to use Familiar syntax for data processing Declarative musical syntax Portable: based on Java Sounds great! Goal for today: react to stock ticker Musician "StockMusician" {     phrase tune = "tune.mid";     "ChangePitch" {         Change Pitch by 3_semitones;     }     "Play" {         ||: tune :||;     } }

Coming up… Intro to Upbeat Upbeat Code Compiler Structure & Tools Peyton Sherwood (Project Manager) Upbeat Code Adrian Weller (Language Guru) Compiler Structure & Tools Fan Lin 林凡 (System Integrator) Runtime Framework Matt D’Zmura (System Architect) Testing & What We’ve Learned Miles Ulrich (Verification and Validation)

Sample Code Conductor Cues Musician “Keyboard” Musician “FunkyDrummer” TIME_SIGNATURE 4/4; TEMPO 140;   Conductor {     cue up = "GoingUp";     cue down = "GoingDown";     cue background = "GoingNowhere";     float param = 0.95;     float threshold = 5.0;     float Avg = 70.0;            // weighted average     Conduct(time currentMeasure) {         Avg = param*Avg + (1-param)*input.currentValue;         Case {          (currentMeasure==1)              Add background currentMeasure;             (input.currentValue > Avg + threshold)                 Add up currentMeasure;             (input.currentValue < Avg - threshold)                 Add down currentMeasure;         }     } } Musician "Keyboard" { phrase intro = "intro.mid";     phrase bridge = "bridge.mid";     phrase UpbeatRules = "upbeatrules.mid";               phrase SongSnippet = "goingdown.mid";                     "GoingNowhere" {      ||: intro | bridge :||;     }     "GoingUp" {         Change Volume to 100; // volume is always in [0,100]         ||: UpbeatRules :||2;     "GoingDown" {         Change Volume to 70;         ||: SongSnippet :||2 ;     }              Musician "FunkyDrummer" {     phrase introdrums = "introdrum.mid";     phrase bridgedrums = "bridgedrum.mid";                phrase funkydrums = "drumpatch.mid";     phrase cymbal = "cymbal.mid";     Change Instrument to 32;            // drums happen to be on MIDI channel 32         "GoingNowhere" {      ||: introdrums | bridgedrums :||;     "GoingUp" {         || funkydrums | cymbal ||; Conductor Cues Musician “Keyboard” CODE HERE Adrian talks about Conductor vs. musician Musician “FunkyDrummer”

Conductor cue up = "GoingUp"; cue down = "GoingDown"; TIME_SIGNATURE 4/4; TEMPO 140;   Conductor {     cue up = "GoingUp";     cue down = "GoingDown";     cue background = "GoingNowhere";     float param = 0.95;     float threshold = 5.0;     float Avg = 70.0;            // weighted average     Conduct(time currentMeasure) {         Avg = param*Avg + (1-param)*input.currentValue;         Case {          (currentMeasure==1)              Add background currentMeasure;             (input.currentValue > Avg + threshold)                 Add up currentMeasure;             (input.currentValue < Avg - threshold)                 Add down currentMeasure;         }     } } Musician "Keyboard" { phrase intro = "intro.mid";     phrase bridge = "bridge.mid";     phrase UpbeatRules = "upbeatrules.mid";               phrase SongSnippet = "goingdown.mid";                     "GoingNowhere" {      ||: intro | bridge :||;     }     "GoingUp" {         Change Volume to 100; // volume is always in [0,100]         ||: UpbeatRules :||2;     "GoingDown" {         Change Volume to 70;         ||: SongSnippet :||2 ;     }              Musician "FunkyDrummer" {     phrase introdrums = "introdrum.mid";     phrase bridgedrums = "bridgedrum.mid";                phrase funkydrums = "drumpatch.mid";     phrase cymbal = "cymbal.mid";     Change Instrument to 32;            // drums happen to be on MIDI channel 32         "GoingNowhere" {      ||: introdrums | bridgedrums :||;     "GoingUp" {         || funkydrums | cymbal ||; cue up = "GoingUp"; cue down = "GoingDown"; cue background = "GoingNowhere"; Avg = param*Avg + (1-param)*input.currentValue; Case { (currentMeasure==1)    Add background currentMeasure;     (input.currentValue > Avg + threshold)         Add up currentMeasure;     (input.currentValue < Avg - threshold)         Add down currentMeasure; } Conductor CODE HERE Adrian talks about Conductor vs. musician

Musician: “Keyboard” "GoingNowhere" { ||: intro | bridge :||; } TIME_SIGNATURE 4/4; TEMPO 140;   Conductor {     cue up = "GoingUp";     cue down = "GoingDown";     cue background = "GoingNowhere";     float param = 0.95;     float threshold = 5.0;     float Avg = 70.0;            // weighted average     Conduct(time currentMeasure) {         Avg = param*Avg + (1-param)*input.currentValue;         Case {          (currentMeasure==1)              Add background currentMeasure;             (input.currentValue > Avg + threshold)                 Add up currentMeasure;             (input.currentValue < Avg - threshold)                 Add down currentMeasure;         }     } } Musician "Keyboard" { phrase intro = "intro.mid";     phrase bridge = "bridge.mid";     phrase UpbeatRules = "upbeatrules.mid";               phrase SongSnippet = "goingdown.mid";                     "GoingNowhere" {      ||: intro | bridge :||;     }     "GoingUp" {         Change Volume to 100; // volume is always in [0,100]         ||: UpbeatRules :||2;     "GoingDown" {         Change Volume to 70;         ||: SongSnippet :||2 ;     }              Musician "FunkyDrummer" {     phrase introdrums = "introdrum.mid";     phrase bridgedrums = "bridgedrum.mid";                phrase funkydrums = "drumpatch.mid";     phrase cymbal = "cymbal.mid";     Change Instrument to 32;            // drums happen to be on MIDI channel 32         "GoingNowhere" {      ||: introdrums | bridgedrums :||;     "GoingUp" {         || funkydrums | cymbal ||; "GoingNowhere" { ||: intro | bridge :||; } "GoingUp" {     Change Volume to 100;     ||: UpbeatRules :||2; }       "GoingDown" {     Change Volume to 70;     ||: SongSnippet :||2 ; }              CODE HERE Adrian talks about Conductor vs. musician Musician: “Keyboard”

Coming up… Intro to Upbeat Upbeat Code Compiler Structure & Tools Peyton Sherwood (Project Manager) Upbeat Code Adrian Weller (Language Guru) Compiler Structure & Tools Fan Lin 林凡 (System Integrator) Runtime Framework Matt D’Zmura (System Architect) Testing & What We’ve Learned Miles Ulrich (Verification and Validation)

Compiler Structure Runtime Framework Music API Front End Lexer Parser jMusic API Wrapper Front End Lexer Parser .up main Java Compiler Our compiler could be divided into three parts: The front end, parsing the upbeat source code and produce source code in target language, which is java. The runtime framework, which will be compiled into a java library and will be used in the compiled java code. The music API, which actually is a part of the runtime framework, dealing with music generation. [Click] When we get a upbeat source code, the Lexer will tokenize the source code and give it to the parser to generate the java code. We put the generated java code and the runtime framework library together. And the main class will also be generated at this time. Then, using java compiler, we compile the generated code together with runtime library. Using JVM to run the target program, and generate music. JVM

System Integration Runtime Framework Music API Front End Lexer Parser jMusic API Wrapper main Front End Lexer Parser .up main main As a system integrator, here I briefly explain how we develop different components at the same time and integrate them together. Basically, we divide our team into 3 groups, they are Front End, Runtime framework and Music API. [Click] To decouple the connection between Front end and the Runtime framework. We created some Sample code which will be generated by the compiler. With these sample code, the runtime framework could be developed and even tested without any front end program. Then, when the front end is developing, they keep a copy of those sample code, and just trying to generate code looks like the sample code. To decouple runtime framework and Music API, we used some intermediate data structure to represent how different pieces of music are assembled. And the music API just read those data structures and generate music. By defining clear interfaces at the very begging, we could develop different components together and integrate them easily.

Tools Runtime Framework Music API Front End Lexer Parser API Wrapper jMusic API Wrapper main Front End Lexer Parser .up Since the compiler is developed using java, we choose those java-friendly tools. We use JFlex as our lexer generator Byacc for java as the parser generator And we found a excellent java music library jMusic to manipulate midi files and generate music Finally, eclipse is our main IDE, and we use google code to host our project and use subversion, a svn plug-in for eclipse to do the version control.

Coming up… Intro to Upbeat Upbeat Code Compiler Structure & Tools Peyton Sherwood (Project Manager) Upbeat Code Adrian Weller (Language Guru) Compiler Structure & Tools Fan Lin 林凡 (System Integrator) Runtime Framework Matt D’Zmura (System Architect) Testing & What We’ve Learned Miles Ulrich (Verification and Validation)

Compiled Upbeat Application Data File Compiled Upbeat Application Drums.mid Strings.mid Horn.mid Piano.mid Input Midi Files

Run-time Process Run-time Framework Measures Cues Input Music API M1: “Drums.mid” M3: “Strings.mid” Measure 1 M2: “Drums.mid” M4: “Strings.mid” Measure 2 Cues M1: GoingNowhere M9: GoingUp M13: GoingUp Data File Input Music API jMusic API Wrapper Keyboard Drummer Conductor Drums.mid Strings.mid Horn.mid Piano.mid Input Midi Files

Coming up… Intro to Upbeat Upbeat Code Compiler Structure & Tools Peyton Sherwood (Project Manager) Upbeat Code Adrian Weller (Language Guru) Compiler Structure & Tools Fan Lin 林凡 (System Integrator) Runtime Framework Matt D’Zmura (System Architect) Testing & What We’ve Learned Miles Ulrich (Verification and Validation)

Testing Setup Unit Tests Upbeat Source Files Lexer + Parser Target Java Code One source file per feature Validate against sample code End-to-End tests Upbeat Source Files Compiler Toolchain Target MIDI Files Collection of source, input Music verified by ear

What we’ve learned Agree on a metaphor early K.I.S.S. Project planning Schedule Weekly check-ins

UPBT: Stock Ticker