SlideShare una empresa de Scribd logo
1 de 85
Timeshift Everything, Miss Nothing Mash up your PVR with Kamaelia Euro OSCON 2006, Brussels Michael Sparks, Senior Research Engineer, BBC Research
[object Object]
[object Object],[object Object],[object Object]
[object Object],[object Object],[object Object],[object Object],[object Object]
[object Object]
[object Object],[object Object]
 
 
 
[object Object]
[object Object]
Kamaelia Macro: Target DVB Multiplex outbox Channel Transcoder inbox DVB  Demuxer  BBC_ONE inbox Channel Transcoder inbox Channel Transcoder inbox Channel Transcoder Channel Transcoder Channel Transcoder inbox inbox inbox BBC_TWO BBC_THREE BBC_FOUR CBEEBIES CBBC
Kamaelia Macro: Status DVB Multiplex outbox Channel Transcoder inbox DVB  Demuxer  BBC_ONE inbox Channel Transcoder inbox Channel Transcoder inbox Channel Transcoder Channel Transcoder Channel Transcoder inbox inbox inbox BBC_TWO BBC_THREE BBC_FOUR CBEEBIES CBBC
Kamaelia Macro: Status Scaling up simply awaiting hardware DVB Multiplex outbox Channel Transcoder inbox DVB  Demuxer  BBC_ONE inbox Channel Transcoder inbox Channel Transcoder inbox Channel Transcoder Channel Transcoder Channel Transcoder inbox inbox inbox BBC_TWO BBC_THREE BBC_FOUR CBEEBIES CBBC
Top Level Schematic DVB Multiplex outbox Channel Transcoder inbox DVB  Demuxer  BBC_ONE inbox
Channel Transcoder Schematic Channel Transcoder EITDemux inbox _eit_ inbox EITParsing outbox inbox Carousel transcoder_factory inbox next outbox
Programme Identification Schematic EIT Parsing PSI Packet Reconstructor inbox inbox EIT Packet Parser outbox inbox Now Next service filter Now Next Changes outbox inbox outbox inbox outbox outbox
Programme Transcoding Schematic (a pipeline) Programme Transcoder Pipethrough (“mencoder -o file options...”) inbox control signal inbox control _transcodingcomplete _stop signal
[object Object]
[object Object]
[object Object]
Aims of this Talk To stave off doom from buggy software on parallel machines
Aims of this Talk ahem
Aims of this Talk (nb, that's something that concerns me, Kamaelia is partly aimed at staving that off, I'm not claiming it does that – but it is one approach we're finding useful)
Aims of this Talk ,[object Object]
Aims of this Talk ,[object Object],[object Object]
Aims of this Talk ,[object Object],[object Object],[object Object]
Aims of this Talk ,[object Object],[object Object],[object Object],[object Object]
Aims of this Talk ,[object Object],[object Object],[object Object],[object Object]
Learning More:  Kamaelia Open Space  ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Aims of this Talk ,[object Object]
[object Object]
[object Object],[object Object]
[object Object]
What you've just seen Component outbox inbox
What you've just seen Component outbox inbox Component outbox inbox
What you've just seen Component outbox inbox Component outbox inbox
What you've just seen Component outbox inbox Component outbox inbox Component outbox inbox
What you've just seen Component outbox inbox Component outbox inbox Component outbox inbox
What you've just seen Component outbox inbox Component outbox inbox Component outbox inbox
What you've just seen Component outbox inbox Component outbox inbox Component outbox inbox
What you've just seen Component outbox inbox Component outbox inbox Component outbox inbox
What you've just seen Component outbox inbox Component outbox inbox Component outbox inbox
What you've just seen Component inbox Component Component outbox outbox  |  inbox outbox  |  inbox
What you've just seen Component inbox Component Component outbox outbox | inbox outbox | inbox
What you've just seen What's inside the box? Component inbox Component Component outbox outbox | inbox outbox | inbox
[object Object]
Python Generators Fibonacci Demo
[object Object]
Component Basics Rotating Angle Demo “ turning a generator into a component”
Component Basics What use is this? class  RotatingAngle(Axon.Component.component): def  main(self): while  1: self.send(x, "outbox") x = x + 1 if x > 359: x = 0 yield  1
Component Basics Consider these components: class loopingCounter(Axon.Component.component) class  cartesianPingPong(Axon.Component.component) class bouncingfloat(Axon.Component.component) class  continuousIdentity(Axon.Component.component) class  continuousZero(Axon.Component.component) class  continuousOne(Axon.Component.component) (from Kamaelia.Automata.Behaviours...)
Component Basics Bouncing Cats
Component Basics Graphline( CAT = BasicSprite(image=cat), ROTATOR = loopingCounter(rotation_speed), MOVER = cartesianPingPong(position, 800, 600, 40), SCALER = bouncingFloat(scale_speed), IMAGER = continuousIdentity(cat), linkages = { ("ROTATOR","outbox" ) : ("CAT", "rotator"), ("MOVER","outbox" )  : ("CAT", "translation"), ("SCALER","outbox" )  : ("CAT", "scaler"), ("IMAGER","outbox" )  : ("CAT", "imaging"), } ).activate() From Examples/SimpleGraphicalApps/BouncingCatGame/Simplegame.py (shutdown fanout removed for space)
[object Object]
Some stuff we've done Networked Audio Mixer Matrix Dirac/Vorbis distribution/decode/players Subtitling distribution server (mobiles, PCs) Presentation Tools Collaborative Whiteboards   * with audio Simple games Visual programming tools Visual Introspection tools Kamaelia Macro ...
Stuff trainees have done pre-university trainee: Previewing PVR content on a mobile phone Shakespeare script parsing and doing something fun with events & data
Stuff trainees have done pre-university trainee: Previewing PVR content on a mobile phone Shakespeare script parsing and doing something fun with events & data Later adapted simply to have the characters talk the play on an IRC channel
Stuff trainees have done Summer trainee: (2 nd  year student) Tools for simple reliable multicast Multicast island joining
Google Summer of Code Students ,[object Object],[object Object],[object Object],[object Object]
Google Summer of Code ,[object Object],[object Object],[object Object],[object Object]
Google Summer of Code ,[object Object],[object Object],[object Object],[object Object],[object Object]
Google Summer of Code ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Ease of Use ,[object Object],[object Object],[object Object],[object Object]
Stuff other parts of the BBC have done Radio & Music Interactive: Prototyped  a system for recording all BBC radio output, transcoding it and making podcasts from the resulting data.
Stuff other parts of the BBC have done Radio & Music Interactive: Prototyped  a system for recording all BBC radio output, transcoding it and making podcasts from the resulting data. Bootstrapped the final system rapidly
Stuff other parts of the BBC have done Radio & Music Interactive: Prototyped  a system for recording all BBC radio output, transcoding it and making podcasts from the resulting data. Bootstrapped the final system rapidly Created the system without any involvement from us
Stuff other parts of the BBC have done Radio & Music Interactive: Prototyped  a system for recording all BBC radio output, transcoding it and making podcasts from the resulting data. This directly led on to the Macro work as a result, including optimisations
Kamaelia Macro: Revisited
[object Object],[object Object]
Top Level Schematic DVB Multiplex outbox Channel Transcoder inbox DVB  Demuxer  BBC_ONE inbox
Top Level Code Graphline( SOURCE=DVB_Multiplex(freq, pids["BBC ONE"]+pids["EIT"], feparams), DEMUX=DVB_Demuxer({ 610: ["BBCONE"], 611: ["BBCONE"], 18: ["BBCONE"], }), BBCONE_HI = ChannelTranscoder(service_ids["BBC ONE"], **params["HI"]), linkages={ ("SOURCE", "outbox"):("DEMUX","inbox"), ("DEMUX", "BBCONE"): ("BBCONE_HI", "inbox"), } ).run()
Channel Transcoder Schematic Channel Transcoder EITDemux inbox _eit_ inbox EITParsing outbox inbox Carousel transcoder_factory inbox next outbox
Channel Transcoder Code def  ChannelTranscoder(service_id, mencoder_options, dir_prefix): def  transcoder_factory(eit): return ProgrammeTranscoder(eit, mencoder_options, dir_prefix) return  Graphline( PROG_CODER = Carousel( transcoder_factory ), EIT_PARSE = EITParsing(service_id), DEMUX = EITDemux(), linkages = { ("self","inbox") : ("DEMUX","inbox"), ("DEMUX","outbox") : ("PROG_CODER","inbox"), ("DEMUX","_eit_") : ("EIT_PARSE", "inbox"), ("EIT_PARSE", "outbox") : ("PROG_CODER", "next"), } )
Programme Identification Schematic EIT Parsing PSI Packet Reconstructor inbox inbox EIT Packet Parser outbox inbox Now Next service filter Now Next Changes outbox inbox outbox inbox outbox outbox
Programme Identification Code def  EITParsing(*service_ids): return pipeline( PSIPacketReconstructor(), EITPacketParser(), NowNextServiceFilter(*service_ids), NowNextChanges(), )
Programme Transcoding Schematic (a pipeline) Programme Transcoder Pipethrough (“mencoder -o file options...”) inbox control signal inbox control _transcodingcomplete _stop signal
Programme Transcoding Code class ProgrammeTranscoder(Axon.Component.component): Inboxes = { "inbox" : "TS packets containing audio and video", "control" : "the usual", "_transcodingcomplete" : "signal from the transcoder", } Outboxes = { "outbox" : "", "_stop" : "stop the transcoder", "signal" : "the usual", } def __init__(self, eitdata, mencoder_options, dir_prefix): super(ProgrammeTranscoder,self).__init__() self.eitdata = eitdata self.mencoder_options =mencoder_options self.dir_prefix = dir_prefix def main(self): # first, generate unique filename uid = str(time.time()) encodingfile = "/data/encoding"+self.dir_prefix+"/"+uid+".avi" waitingEIT  = "/data/encoding"+self.dir_prefix+"/"+uid+".eit" finishedfile = "/data/finished"+self.dir_prefix+"/"+uid+".avi" finishedEIT  = "/data/finished"+self.dir_prefix+"/"+uid+".eit" print uid,"Starting transcoding into: "+encodingfile transcoder = Pipethrough("mencoder -o "+encodingfile+" "+self.mencoder_options) print uid,"Transcoder pipethough =",transcoder.name data_linkage = self.link( (self,"inbox"), (transcoder,"inbox"), passthrough=1 ) ctrl_linkage = self.link( (self,"_stop"), (transcoder,"control")) done_linkage = self.link( (transcoder,"signal"), (self,"_transcodingcomplete") )
Kamaelia Macro ,[object Object],[object Object]
But Why Mashup?  ,[object Object],[object Object],[object Object]
Kamaelia: Ideas  ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]
Kamaelia Futures ,[object Object],[object Object],[object Object],[object Object],(AKA Specfic stuff we want to do)
Kamaelia Futures ,[object Object],[object Object],[object Object],[object Object],[object Object],(AKA Specfic stuff we want to do)
Thank you! Thank you!
Kamaelia Open Space  ,[object Object],[object Object],[object Object],[object Object],[object Object],[object Object]

Más contenido relacionado

Destacado

Kamaelia lightning2010opensource
Kamaelia lightning2010opensourceKamaelia lightning2010opensource
Kamaelia lightning2010opensourcekamaelian
 
RabbitMQ with python and ruby RuPy 2009
RabbitMQ with python and ruby RuPy 2009RabbitMQ with python and ruby RuPy 2009
RabbitMQ with python and ruby RuPy 2009Paolo Negri
 
Practical concurrent systems made simple using Kamaelia
Practical concurrent systems made simple using KamaeliaPractical concurrent systems made simple using Kamaelia
Practical concurrent systems made simple using Kamaeliakamaelian
 
Descriptors In Python
Descriptors In PythonDescriptors In Python
Descriptors In PythonAmit Upadhyay
 
Messaging with RabbitMQ and AMQP
Messaging with RabbitMQ and AMQPMessaging with RabbitMQ and AMQP
Messaging with RabbitMQ and AMQPEberhard Wolff
 
Data Analysis and Statistics in Python using pandas and statsmodels
Data Analysis and Statistics in Python using pandas and statsmodelsData Analysis and Statistics in Python using pandas and statsmodels
Data Analysis and Statistics in Python using pandas and statsmodelsWes McKinney
 
Django for Beginners
Django for BeginnersDjango for Beginners
Django for BeginnersJason Davies
 
Introduction To Django
Introduction To DjangoIntroduction To Django
Introduction To DjangoJay Graves
 
Python for Financial Data Analysis with pandas
Python for Financial Data Analysis with pandasPython for Financial Data Analysis with pandas
Python for Financial Data Analysis with pandasWes McKinney
 
Advance OOP concepts in Python
Advance OOP concepts in PythonAdvance OOP concepts in Python
Advance OOP concepts in PythonSujith Kumar
 
Python Advanced – Building on the foundation
Python Advanced – Building on the foundationPython Advanced – Building on the foundation
Python Advanced – Building on the foundationKevlin Henney
 
Python Tricks That You Can't Live Without
Python Tricks That You Can't Live WithoutPython Tricks That You Can't Live Without
Python Tricks That You Can't Live WithoutAudrey Roy
 
Improving Python and Spark Performance and Interoperability: Spark Summit Eas...
Improving Python and Spark Performance and Interoperability: Spark Summit Eas...Improving Python and Spark Performance and Interoperability: Spark Summit Eas...
Improving Python and Spark Performance and Interoperability: Spark Summit Eas...Spark Summit
 
Web Development with Python and Django
Web Development with Python and DjangoWeb Development with Python and Django
Web Development with Python and DjangoMichael Pirnat
 

Destacado (15)

Kamaelia lightning2010opensource
Kamaelia lightning2010opensourceKamaelia lightning2010opensource
Kamaelia lightning2010opensource
 
RabbitMQ with python and ruby RuPy 2009
RabbitMQ with python and ruby RuPy 2009RabbitMQ with python and ruby RuPy 2009
RabbitMQ with python and ruby RuPy 2009
 
Practical concurrent systems made simple using Kamaelia
Practical concurrent systems made simple using KamaeliaPractical concurrent systems made simple using Kamaelia
Practical concurrent systems made simple using Kamaelia
 
Descriptors In Python
Descriptors In PythonDescriptors In Python
Descriptors In Python
 
Messaging with RabbitMQ and AMQP
Messaging with RabbitMQ and AMQPMessaging with RabbitMQ and AMQP
Messaging with RabbitMQ and AMQP
 
Django introduction
Django introductionDjango introduction
Django introduction
 
Data Analysis and Statistics in Python using pandas and statsmodels
Data Analysis and Statistics in Python using pandas and statsmodelsData Analysis and Statistics in Python using pandas and statsmodels
Data Analysis and Statistics in Python using pandas and statsmodels
 
Django for Beginners
Django for BeginnersDjango for Beginners
Django for Beginners
 
Introduction To Django
Introduction To DjangoIntroduction To Django
Introduction To Django
 
Python for Financial Data Analysis with pandas
Python for Financial Data Analysis with pandasPython for Financial Data Analysis with pandas
Python for Financial Data Analysis with pandas
 
Advance OOP concepts in Python
Advance OOP concepts in PythonAdvance OOP concepts in Python
Advance OOP concepts in Python
 
Python Advanced – Building on the foundation
Python Advanced – Building on the foundationPython Advanced – Building on the foundation
Python Advanced – Building on the foundation
 
Python Tricks That You Can't Live Without
Python Tricks That You Can't Live WithoutPython Tricks That You Can't Live Without
Python Tricks That You Can't Live Without
 
Improving Python and Spark Performance and Interoperability: Spark Summit Eas...
Improving Python and Spark Performance and Interoperability: Spark Summit Eas...Improving Python and Spark Performance and Interoperability: Spark Summit Eas...
Improving Python and Spark Performance and Interoperability: Spark Summit Eas...
 
Web Development with Python and Django
Web Development with Python and DjangoWeb Development with Python and Django
Web Development with Python and Django
 

Similar a Timeshift Everything, Miss Nothing - Mashup your PVR with Kamaelia

Open frameworks 101_fitc
Open frameworks 101_fitcOpen frameworks 101_fitc
Open frameworks 101_fitcbenDesigning
 
OSCON 2010 Brendan Quinn - Ingex:bringing open source to the broadcast indust...
OSCON 2010 Brendan Quinn - Ingex:bringing open source to the broadcast indust...OSCON 2010 Brendan Quinn - Ingex:bringing open source to the broadcast indust...
OSCON 2010 Brendan Quinn - Ingex:bringing open source to the broadcast indust...Brendan Quinn
 
Setup VoIP System and Interconnection with LTE network
Setup VoIP System and Interconnection with LTE networkSetup VoIP System and Interconnection with LTE network
Setup VoIP System and Interconnection with LTE networkNazmul Hossain Rakib
 
Beyond live streaming 2 way communications
Beyond live streaming 2 way communications Beyond live streaming 2 way communications
Beyond live streaming 2 way communications Paul Richards
 
Hacking the Kinect with GAFFTA Day 1
Hacking the Kinect with GAFFTA Day 1Hacking the Kinect with GAFFTA Day 1
Hacking the Kinect with GAFFTA Day 1benDesigning
 
Rubato Introduction
Rubato IntroductionRubato Introduction
Rubato Introductionjdiloreto
 
Python Online Compiler
Python Online CompilerPython Online Compiler
Python Online CompilerMr Examples
 
Uip Sip Implementation Best Practices060409
Uip Sip Implementation Best Practices060409Uip Sip Implementation Best Practices060409
Uip Sip Implementation Best Practices060409Abdel-Fattah M. Hmoud
 
Smart TV Security - #1984 in 21st century -
Smart TV Security - #1984 in 21st century -Smart TV Security - #1984 in 21st century -
Smart TV Security - #1984 in 21st century -Seungjoo Kim
 
Challenges and experiences with IPTV from a network point of view
Challenges and experiences with IPTV from a network point of viewChallenges and experiences with IPTV from a network point of view
Challenges and experiences with IPTV from a network point of viewbrouer
 
Hacking, Surveilling, and Deceiving Victims on Smart TV
Hacking, Surveilling, and Deceiving Victims on Smart TVHacking, Surveilling, and Deceiving Victims on Smart TV
Hacking, Surveilling, and Deceiving Victims on Smart TVSeungjoo Kim
 
Understanding and building Your Own Docker
Understanding and building Your Own DockerUnderstanding and building Your Own Docker
Understanding and building Your Own DockerMotiejus Jakštys
 
Breizhcamp: Créer un bot, pas si simple. Faisons le point.
Breizhcamp: Créer un bot, pas si simple. Faisons le point.Breizhcamp: Créer un bot, pas si simple. Faisons le point.
Breizhcamp: Créer un bot, pas si simple. Faisons le point.Cisco DevNet
 
Eclipse 3.7 : Tips and tricks
Eclipse 3.7 : Tips and tricksEclipse 3.7 : Tips and tricks
Eclipse 3.7 : Tips and tricksTomasz Zarna
 
Talk at the Landelijk Architecure Congress (NL)
Talk at the Landelijk Architecure Congress (NL)Talk at the Landelijk Architecure Congress (NL)
Talk at the Landelijk Architecure Congress (NL)Jonathan Carter
 
Exploring the Internet of Things Using Ruby
Exploring the Internet of Things Using RubyExploring the Internet of Things Using Ruby
Exploring the Internet of Things Using RubyMike Hagedorn
 
Building frameworks: from concept to completion
Building frameworks: from concept to completionBuilding frameworks: from concept to completion
Building frameworks: from concept to completionRuben Goncalves
 

Similar a Timeshift Everything, Miss Nothing - Mashup your PVR with Kamaelia (20)

Open frameworks 101_fitc
Open frameworks 101_fitcOpen frameworks 101_fitc
Open frameworks 101_fitc
 
OSCON 2010 Brendan Quinn - Ingex:bringing open source to the broadcast indust...
OSCON 2010 Brendan Quinn - Ingex:bringing open source to the broadcast indust...OSCON 2010 Brendan Quinn - Ingex:bringing open source to the broadcast indust...
OSCON 2010 Brendan Quinn - Ingex:bringing open source to the broadcast indust...
 
Setup VoIP System and Interconnection with LTE network
Setup VoIP System and Interconnection with LTE networkSetup VoIP System and Interconnection with LTE network
Setup VoIP System and Interconnection with LTE network
 
Beyond live streaming 2 way communications
Beyond live streaming 2 way communications Beyond live streaming 2 way communications
Beyond live streaming 2 way communications
 
Hacking the Kinect with GAFFTA Day 1
Hacking the Kinect with GAFFTA Day 1Hacking the Kinect with GAFFTA Day 1
Hacking the Kinect with GAFFTA Day 1
 
Rubato Introduction
Rubato IntroductionRubato Introduction
Rubato Introduction
 
Python Online Compiler
Python Online CompilerPython Online Compiler
Python Online Compiler
 
Uip Sip Implementation Best Practices060409
Uip Sip Implementation Best Practices060409Uip Sip Implementation Best Practices060409
Uip Sip Implementation Best Practices060409
 
WebRTC Status Update - 2017Q2
WebRTC Status Update - 2017Q2WebRTC Status Update - 2017Q2
WebRTC Status Update - 2017Q2
 
Smart TV Security - #1984 in 21st century -
Smart TV Security - #1984 in 21st century -Smart TV Security - #1984 in 21st century -
Smart TV Security - #1984 in 21st century -
 
Challenges and experiences with IPTV from a network point of view
Challenges and experiences with IPTV from a network point of viewChallenges and experiences with IPTV from a network point of view
Challenges and experiences with IPTV from a network point of view
 
Hacking, Surveilling, and Deceiving Victims on Smart TV
Hacking, Surveilling, and Deceiving Victims on Smart TVHacking, Surveilling, and Deceiving Victims on Smart TV
Hacking, Surveilling, and Deceiving Victims on Smart TV
 
Understanding and building Your Own Docker
Understanding and building Your Own DockerUnderstanding and building Your Own Docker
Understanding and building Your Own Docker
 
Breizhcamp: Créer un bot, pas si simple. Faisons le point.
Breizhcamp: Créer un bot, pas si simple. Faisons le point.Breizhcamp: Créer un bot, pas si simple. Faisons le point.
Breizhcamp: Créer un bot, pas si simple. Faisons le point.
 
Eclipse 3.7 : Tips and tricks
Eclipse 3.7 : Tips and tricksEclipse 3.7 : Tips and tricks
Eclipse 3.7 : Tips and tricks
 
Origo mdn 2015
Origo   mdn 2015Origo   mdn 2015
Origo mdn 2015
 
Talk at the Landelijk Architecure Congress (NL)
Talk at the Landelijk Architecure Congress (NL)Talk at the Landelijk Architecure Congress (NL)
Talk at the Landelijk Architecure Congress (NL)
 
Exploring the Internet of Things Using Ruby
Exploring the Internet of Things Using RubyExploring the Internet of Things Using Ruby
Exploring the Internet of Things Using Ruby
 
Cassandra @ Yahoo Japan | Cassandra Summit 2016
Cassandra @ Yahoo Japan | Cassandra Summit 2016Cassandra @ Yahoo Japan | Cassandra Summit 2016
Cassandra @ Yahoo Japan | Cassandra Summit 2016
 
Building frameworks: from concept to completion
Building frameworks: from concept to completionBuilding frameworks: from concept to completion
Building frameworks: from concept to completion
 

Más de kamaelian

Sharing Data and Services Safely in Concurrent Systems using Kamaelia
Sharing Data and Services Safely in Concurrent Systems using KamaeliaSharing Data and Services Safely in Concurrent Systems using Kamaelia
Sharing Data and Services Safely in Concurrent Systems using Kamaeliakamaelian
 
Sociable Software
Sociable SoftwareSociable Software
Sociable Softwarekamaelian
 
Open Source at the BBC: When, Why, Why not & How
Open Source at the BBC: When, Why, Why not & HowOpen Source at the BBC: When, Why, Why not & How
Open Source at the BBC: When, Why, Why not & Howkamaelian
 
Open Source at the BBC
Open Source at the BBCOpen Source at the BBC
Open Source at the BBCkamaelian
 
Kamaelia - Fave 2005
Kamaelia - Fave 2005Kamaelia - Fave 2005
Kamaelia - Fave 2005kamaelian
 
SWP - A Generic Language Parser
SWP - A Generic Language ParserSWP - A Generic Language Parser
SWP - A Generic Language Parserkamaelian
 
Kamaelia - Networking Using Generators
Kamaelia - Networking Using GeneratorsKamaelia - Networking Using Generators
Kamaelia - Networking Using Generatorskamaelian
 
Scaling Streaming - Concepts, Research, Goals
Scaling Streaming - Concepts, Research, GoalsScaling Streaming - Concepts, Research, Goals
Scaling Streaming - Concepts, Research, Goalskamaelian
 
Kamaelia Internals
Kamaelia InternalsKamaelia Internals
Kamaelia Internalskamaelian
 
Building systems with Kamaelia
Building systems with KamaeliaBuilding systems with Kamaelia
Building systems with Kamaeliakamaelian
 
Free software: How does it work?
Free software: How does it work?Free software: How does it work?
Free software: How does it work?kamaelian
 

Más de kamaelian (11)

Sharing Data and Services Safely in Concurrent Systems using Kamaelia
Sharing Data and Services Safely in Concurrent Systems using KamaeliaSharing Data and Services Safely in Concurrent Systems using Kamaelia
Sharing Data and Services Safely in Concurrent Systems using Kamaelia
 
Sociable Software
Sociable SoftwareSociable Software
Sociable Software
 
Open Source at the BBC: When, Why, Why not & How
Open Source at the BBC: When, Why, Why not & HowOpen Source at the BBC: When, Why, Why not & How
Open Source at the BBC: When, Why, Why not & How
 
Open Source at the BBC
Open Source at the BBCOpen Source at the BBC
Open Source at the BBC
 
Kamaelia - Fave 2005
Kamaelia - Fave 2005Kamaelia - Fave 2005
Kamaelia - Fave 2005
 
SWP - A Generic Language Parser
SWP - A Generic Language ParserSWP - A Generic Language Parser
SWP - A Generic Language Parser
 
Kamaelia - Networking Using Generators
Kamaelia - Networking Using GeneratorsKamaelia - Networking Using Generators
Kamaelia - Networking Using Generators
 
Scaling Streaming - Concepts, Research, Goals
Scaling Streaming - Concepts, Research, GoalsScaling Streaming - Concepts, Research, Goals
Scaling Streaming - Concepts, Research, Goals
 
Kamaelia Internals
Kamaelia InternalsKamaelia Internals
Kamaelia Internals
 
Building systems with Kamaelia
Building systems with KamaeliaBuilding systems with Kamaelia
Building systems with Kamaelia
 
Free software: How does it work?
Free software: How does it work?Free software: How does it work?
Free software: How does it work?
 

Último

Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobeapidays
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesBoston Institute of Analytics
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?Igalia
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024The Digital Insurer
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MIND CTI
 

Último (20)

Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 

Timeshift Everything, Miss Nothing - Mashup your PVR with Kamaelia

  • 1. Timeshift Everything, Miss Nothing Mash up your PVR with Kamaelia Euro OSCON 2006, Brussels Michael Sparks, Senior Research Engineer, BBC Research
  • 2.
  • 3.
  • 4.
  • 5.
  • 6.
  • 7.  
  • 8.  
  • 9.  
  • 10.
  • 11.
  • 12. Kamaelia Macro: Target DVB Multiplex outbox Channel Transcoder inbox DVB Demuxer BBC_ONE inbox Channel Transcoder inbox Channel Transcoder inbox Channel Transcoder Channel Transcoder Channel Transcoder inbox inbox inbox BBC_TWO BBC_THREE BBC_FOUR CBEEBIES CBBC
  • 13. Kamaelia Macro: Status DVB Multiplex outbox Channel Transcoder inbox DVB Demuxer BBC_ONE inbox Channel Transcoder inbox Channel Transcoder inbox Channel Transcoder Channel Transcoder Channel Transcoder inbox inbox inbox BBC_TWO BBC_THREE BBC_FOUR CBEEBIES CBBC
  • 14. Kamaelia Macro: Status Scaling up simply awaiting hardware DVB Multiplex outbox Channel Transcoder inbox DVB Demuxer BBC_ONE inbox Channel Transcoder inbox Channel Transcoder inbox Channel Transcoder Channel Transcoder Channel Transcoder inbox inbox inbox BBC_TWO BBC_THREE BBC_FOUR CBEEBIES CBBC
  • 15. Top Level Schematic DVB Multiplex outbox Channel Transcoder inbox DVB Demuxer BBC_ONE inbox
  • 16. Channel Transcoder Schematic Channel Transcoder EITDemux inbox _eit_ inbox EITParsing outbox inbox Carousel transcoder_factory inbox next outbox
  • 17. Programme Identification Schematic EIT Parsing PSI Packet Reconstructor inbox inbox EIT Packet Parser outbox inbox Now Next service filter Now Next Changes outbox inbox outbox inbox outbox outbox
  • 18. Programme Transcoding Schematic (a pipeline) Programme Transcoder Pipethrough (“mencoder -o file options...”) inbox control signal inbox control _transcodingcomplete _stop signal
  • 19.
  • 20.
  • 21.
  • 22. Aims of this Talk To stave off doom from buggy software on parallel machines
  • 23. Aims of this Talk ahem
  • 24. Aims of this Talk (nb, that's something that concerns me, Kamaelia is partly aimed at staving that off, I'm not claiming it does that – but it is one approach we're finding useful)
  • 25.
  • 26.
  • 27.
  • 28.
  • 29.
  • 30.
  • 31.
  • 32.
  • 33.
  • 34.
  • 35. What you've just seen Component outbox inbox
  • 36. What you've just seen Component outbox inbox Component outbox inbox
  • 37. What you've just seen Component outbox inbox Component outbox inbox
  • 38. What you've just seen Component outbox inbox Component outbox inbox Component outbox inbox
  • 39. What you've just seen Component outbox inbox Component outbox inbox Component outbox inbox
  • 40. What you've just seen Component outbox inbox Component outbox inbox Component outbox inbox
  • 41. What you've just seen Component outbox inbox Component outbox inbox Component outbox inbox
  • 42. What you've just seen Component outbox inbox Component outbox inbox Component outbox inbox
  • 43. What you've just seen Component outbox inbox Component outbox inbox Component outbox inbox
  • 44. What you've just seen Component inbox Component Component outbox outbox | inbox outbox | inbox
  • 45. What you've just seen Component inbox Component Component outbox outbox | inbox outbox | inbox
  • 46. What you've just seen What's inside the box? Component inbox Component Component outbox outbox | inbox outbox | inbox
  • 47.
  • 49.
  • 50. Component Basics Rotating Angle Demo “ turning a generator into a component”
  • 51. Component Basics What use is this? class RotatingAngle(Axon.Component.component): def main(self): while 1: self.send(x, "outbox") x = x + 1 if x > 359: x = 0 yield 1
  • 52. Component Basics Consider these components: class loopingCounter(Axon.Component.component) class cartesianPingPong(Axon.Component.component) class bouncingfloat(Axon.Component.component) class continuousIdentity(Axon.Component.component) class continuousZero(Axon.Component.component) class continuousOne(Axon.Component.component) (from Kamaelia.Automata.Behaviours...)
  • 54. Component Basics Graphline( CAT = BasicSprite(image=cat), ROTATOR = loopingCounter(rotation_speed), MOVER = cartesianPingPong(position, 800, 600, 40), SCALER = bouncingFloat(scale_speed), IMAGER = continuousIdentity(cat), linkages = { ("ROTATOR","outbox" ) : ("CAT", "rotator"), ("MOVER","outbox" ) : ("CAT", "translation"), ("SCALER","outbox" ) : ("CAT", "scaler"), ("IMAGER","outbox" ) : ("CAT", "imaging"), } ).activate() From Examples/SimpleGraphicalApps/BouncingCatGame/Simplegame.py (shutdown fanout removed for space)
  • 55.
  • 56. Some stuff we've done Networked Audio Mixer Matrix Dirac/Vorbis distribution/decode/players Subtitling distribution server (mobiles, PCs) Presentation Tools Collaborative Whiteboards * with audio Simple games Visual programming tools Visual Introspection tools Kamaelia Macro ...
  • 57. Stuff trainees have done pre-university trainee: Previewing PVR content on a mobile phone Shakespeare script parsing and doing something fun with events & data
  • 58. Stuff trainees have done pre-university trainee: Previewing PVR content on a mobile phone Shakespeare script parsing and doing something fun with events & data Later adapted simply to have the characters talk the play on an IRC channel
  • 59. Stuff trainees have done Summer trainee: (2 nd year student) Tools for simple reliable multicast Multicast island joining
  • 60.
  • 61.
  • 62.
  • 63.
  • 64.
  • 65. Stuff other parts of the BBC have done Radio & Music Interactive: Prototyped a system for recording all BBC radio output, transcoding it and making podcasts from the resulting data.
  • 66. Stuff other parts of the BBC have done Radio & Music Interactive: Prototyped a system for recording all BBC radio output, transcoding it and making podcasts from the resulting data. Bootstrapped the final system rapidly
  • 67. Stuff other parts of the BBC have done Radio & Music Interactive: Prototyped a system for recording all BBC radio output, transcoding it and making podcasts from the resulting data. Bootstrapped the final system rapidly Created the system without any involvement from us
  • 68. Stuff other parts of the BBC have done Radio & Music Interactive: Prototyped a system for recording all BBC radio output, transcoding it and making podcasts from the resulting data. This directly led on to the Macro work as a result, including optimisations
  • 70.
  • 71. Top Level Schematic DVB Multiplex outbox Channel Transcoder inbox DVB Demuxer BBC_ONE inbox
  • 72. Top Level Code Graphline( SOURCE=DVB_Multiplex(freq, pids["BBC ONE"]+pids["EIT"], feparams), DEMUX=DVB_Demuxer({ 610: ["BBCONE"], 611: ["BBCONE"], 18: ["BBCONE"], }), BBCONE_HI = ChannelTranscoder(service_ids["BBC ONE"], **params["HI"]), linkages={ ("SOURCE", "outbox"):("DEMUX","inbox"), ("DEMUX", "BBCONE"): ("BBCONE_HI", "inbox"), } ).run()
  • 73. Channel Transcoder Schematic Channel Transcoder EITDemux inbox _eit_ inbox EITParsing outbox inbox Carousel transcoder_factory inbox next outbox
  • 74. Channel Transcoder Code def ChannelTranscoder(service_id, mencoder_options, dir_prefix): def transcoder_factory(eit): return ProgrammeTranscoder(eit, mencoder_options, dir_prefix) return Graphline( PROG_CODER = Carousel( transcoder_factory ), EIT_PARSE = EITParsing(service_id), DEMUX = EITDemux(), linkages = { ("self","inbox") : ("DEMUX","inbox"), ("DEMUX","outbox") : ("PROG_CODER","inbox"), ("DEMUX","_eit_") : ("EIT_PARSE", "inbox"), ("EIT_PARSE", "outbox") : ("PROG_CODER", "next"), } )
  • 75. Programme Identification Schematic EIT Parsing PSI Packet Reconstructor inbox inbox EIT Packet Parser outbox inbox Now Next service filter Now Next Changes outbox inbox outbox inbox outbox outbox
  • 76. Programme Identification Code def EITParsing(*service_ids): return pipeline( PSIPacketReconstructor(), EITPacketParser(), NowNextServiceFilter(*service_ids), NowNextChanges(), )
  • 77. Programme Transcoding Schematic (a pipeline) Programme Transcoder Pipethrough (“mencoder -o file options...”) inbox control signal inbox control _transcodingcomplete _stop signal
  • 78. Programme Transcoding Code class ProgrammeTranscoder(Axon.Component.component): Inboxes = { "inbox" : "TS packets containing audio and video", "control" : "the usual", "_transcodingcomplete" : "signal from the transcoder", } Outboxes = { "outbox" : "", "_stop" : "stop the transcoder", "signal" : "the usual", } def __init__(self, eitdata, mencoder_options, dir_prefix): super(ProgrammeTranscoder,self).__init__() self.eitdata = eitdata self.mencoder_options =mencoder_options self.dir_prefix = dir_prefix def main(self): # first, generate unique filename uid = str(time.time()) encodingfile = "/data/encoding"+self.dir_prefix+"/"+uid+".avi" waitingEIT = "/data/encoding"+self.dir_prefix+"/"+uid+".eit" finishedfile = "/data/finished"+self.dir_prefix+"/"+uid+".avi" finishedEIT = "/data/finished"+self.dir_prefix+"/"+uid+".eit" print uid,"Starting transcoding into: "+encodingfile transcoder = Pipethrough("mencoder -o "+encodingfile+" "+self.mencoder_options) print uid,"Transcoder pipethough =",transcoder.name data_linkage = self.link( (self,"inbox"), (transcoder,"inbox"), passthrough=1 ) ctrl_linkage = self.link( (self,"_stop"), (transcoder,"control")) done_linkage = self.link( (transcoder,"signal"), (self,"_transcodingcomplete") )
  • 79.
  • 80.
  • 81.
  • 82.
  • 83.
  • 85.