SlideShare a Scribd company logo
1 of 15
Download to read offline
Presented
by:
Ibis and Substrait: Standardized
Analytics
06/23/2022
Hussain Sultan
2
Ibis produces Expressions or Strings for
execution on SQL backends
t.groupby('region')
.aggregate(topk=t.funding_rounds.count())
.sort_by(ibis.desc('topk'))
.head()
Produces
SELECT region
,count(funding_rounds) AS topk
FROM companies
GROUP BY region
ORDER BY topk
SQL Strings generated for
Execution Engine
SQL
Backends
<sqlalchemy.sql.selectable.S
elect object>
SQLAlchemy Expression
3
String Execution Backend
Ibis API Operations Compile SQL String
Backend Specific SQL Flavor and Support
Type Check and Optimize
Rewrite
Build Ibis Expression
4
Expression Generating Backends
API Operation Compile
SA
Expression
Backend Specific Expressions or SQLAlchemy
Type Check and Optimize
Rewrite
Build Ibis Expression
5
Ibis Backends - LOC
SQLAlchemy-based
Backends tend to be lower LOC
6
What if Ibis supported 100’s of backends?
DB Engines lists 398 Databases in their popularity ranking
https://db-engines.com/en/ranking
7
Substrait: Serialized Relational Algebra
substrait
views
ibis
python r scala
babel sql presto sql
dplyr
Producers
Consumers
ibis
8
Substrait: Serialized Relational Algebra
Plan
Relations
Types
i8 i32
fp32 struct
Expressions
Functions
add
rank
join agg
filter read
case
literal
Serialization
protobuf text
● Types
● Expressions
● Functions
● Relations
● Plans
● Serialization formats
9
What’s Next?
10
Ibis-substrait producer is actively being
developed
SQL
String
Python
Expression
Under Development
Ibis API
Compile
Substrait
Producer
11
Demo
12
Takeaways
● Ibis as a substrait producer, decouples the execution
engines and expression building
● Check out Gil Forsyth’s gist that explains the duckdb and
ibis substrait integration:
https://gist.github.com/gforsyth/496d680e1e29f0876df937e
e5091e1b8
13
Thank you!
14
2. What if we want to consume any SQL
DSL into Ibis expressions?
API Ops
DSL Execute
15
Ibis support multiple execution paradigms
SQL
String
Python
Expression
Direct
Execution
Focus of Today’s Talk
1
Ibis API
2
Compile

More Related Content

Similar to Ibis + Substrait.pdf

Visualforce for the Salesforce1 Platform
Visualforce for the Salesforce1 PlatformVisualforce for the Salesforce1 Platform
Visualforce for the Salesforce1 Platform
sg8002
 
Introduction to Threading in .Net
Introduction to Threading in .NetIntroduction to Threading in .Net
Introduction to Threading in .Net
webhostingguy
 

Similar to Ibis + Substrait.pdf (20)

Oracle_EBS_Technical.pptx
Oracle_EBS_Technical.pptxOracle_EBS_Technical.pptx
Oracle_EBS_Technical.pptx
 
BI 2008 Simple
BI 2008 SimpleBI 2008 Simple
BI 2008 Simple
 
Mastering solr
Mastering solrMastering solr
Mastering solr
 
Create column store index on all supported tables in sql server 2014 copy
Create column store index on all supported tables in sql server 2014    copyCreate column store index on all supported tables in sql server 2014    copy
Create column store index on all supported tables in sql server 2014 copy
 
ALV with Integrated Data Access
ALV with Integrated Data AccessALV with Integrated Data Access
ALV with Integrated Data Access
 
Wix Machine Learning - Ran Romano
Wix Machine Learning - Ran RomanoWix Machine Learning - Ran Romano
Wix Machine Learning - Ran Romano
 
Hibernate 6.1 - What's new.pdf
Hibernate 6.1 - What's new.pdfHibernate 6.1 - What's new.pdf
Hibernate 6.1 - What's new.pdf
 
SQL Server 2008 Integration Services
SQL Server 2008 Integration ServicesSQL Server 2008 Integration Services
SQL Server 2008 Integration Services
 
Visualforce for the Salesforce1 Platform
Visualforce for the Salesforce1 PlatformVisualforce for the Salesforce1 Platform
Visualforce for the Salesforce1 Platform
 
Coding the Salesforce User Interface with Visualforce Pages
Coding the Salesforce User Interface with Visualforce PagesCoding the Salesforce User Interface with Visualforce Pages
Coding the Salesforce User Interface with Visualforce Pages
 
Introduction to Threading in .Net
Introduction to Threading in .NetIntroduction to Threading in .Net
Introduction to Threading in .Net
 
hbaseconasia2019 Distributed Bitmap Index Solution
hbaseconasia2019 Distributed Bitmap Index Solutionhbaseconasia2019 Distributed Bitmap Index Solution
hbaseconasia2019 Distributed Bitmap Index Solution
 
WEBINAR - Introducing Scylla Open Source 3.0: Materialized Views, Secondary I...
WEBINAR - Introducing Scylla Open Source 3.0: Materialized Views, Secondary I...WEBINAR - Introducing Scylla Open Source 3.0: Materialized Views, Secondary I...
WEBINAR - Introducing Scylla Open Source 3.0: Materialized Views, Secondary I...
 
Introduction to Force.com
Introduction to Force.comIntroduction to Force.com
Introduction to Force.com
 
Day2
Day2Day2
Day2
 
SQL Server 2008 Data Mining
SQL Server 2008 Data MiningSQL Server 2008 Data Mining
SQL Server 2008 Data Mining
 
Spark Sql for Training
Spark Sql for TrainingSpark Sql for Training
Spark Sql for Training
 
Generating Code with Oracle SQL Developer Data Modeler
Generating Code with Oracle SQL Developer Data ModelerGenerating Code with Oracle SQL Developer Data Modeler
Generating Code with Oracle SQL Developer Data Modeler
 
My sql susecon_crashcourse_2012
My sql susecon_crashcourse_2012My sql susecon_crashcourse_2012
My sql susecon_crashcourse_2012
 
Ims11 ims13 application programming enhancements - IMS UG May 2014 Sydney & ...
Ims11  ims13 application programming enhancements - IMS UG May 2014 Sydney & ...Ims11  ims13 application programming enhancements - IMS UG May 2014 Sydney & ...
Ims11 ims13 application programming enhancements - IMS UG May 2014 Sydney & ...
 

Recently uploaded

Obat Aborsi Surabaya 0851\7696\3835 Jual Obat Cytotec Di Surabaya
Obat Aborsi Surabaya 0851\7696\3835 Jual Obat Cytotec Di SurabayaObat Aborsi Surabaya 0851\7696\3835 Jual Obat Cytotec Di Surabaya
Obat Aborsi Surabaya 0851\7696\3835 Jual Obat Cytotec Di Surabaya
Obat Aborsi Jakarta Wa 085176963835 Apotek Jual Obat Cytotec Di Jakarta
 
NewBase 17 May 2024 Energy News issue - 1725 by Khaled Al Awadi_compresse...
NewBase   17 May  2024  Energy News issue - 1725 by Khaled Al Awadi_compresse...NewBase   17 May  2024  Energy News issue - 1725 by Khaled Al Awadi_compresse...
NewBase 17 May 2024 Energy News issue - 1725 by Khaled Al Awadi_compresse...
Khaled Al Awadi
 
A BUSINESS PROPOSAL FOR SLAUGHTER HOUSE WASTE MANAGEMENT IN MYSORE MUNICIPAL ...
A BUSINESS PROPOSAL FOR SLAUGHTER HOUSE WASTE MANAGEMENT IN MYSORE MUNICIPAL ...A BUSINESS PROPOSAL FOR SLAUGHTER HOUSE WASTE MANAGEMENT IN MYSORE MUNICIPAL ...
A BUSINESS PROPOSAL FOR SLAUGHTER HOUSE WASTE MANAGEMENT IN MYSORE MUNICIPAL ...
prakheeshc
 

Recently uploaded (20)

10 Easiest Ways To Buy Verified TransferWise Accounts
10 Easiest Ways To Buy Verified TransferWise Accounts10 Easiest Ways To Buy Verified TransferWise Accounts
10 Easiest Ways To Buy Verified TransferWise Accounts
 
Elevate Your Online Presence with SEO Services
Elevate Your Online Presence with SEO ServicesElevate Your Online Presence with SEO Services
Elevate Your Online Presence with SEO Services
 
Moradia Isolada com Logradouro; Detached house with patio in Penacova
Moradia Isolada com Logradouro; Detached house with patio in PenacovaMoradia Isolada com Logradouro; Detached house with patio in Penacova
Moradia Isolada com Logradouro; Detached house with patio in Penacova
 
Obat Aborsi Surabaya 0851\7696\3835 Jual Obat Cytotec Di Surabaya
Obat Aborsi Surabaya 0851\7696\3835 Jual Obat Cytotec Di SurabayaObat Aborsi Surabaya 0851\7696\3835 Jual Obat Cytotec Di Surabaya
Obat Aborsi Surabaya 0851\7696\3835 Jual Obat Cytotec Di Surabaya
 
Should Law Firms Outsource their Bookkeeping
Should Law Firms Outsource their BookkeepingShould Law Firms Outsource their Bookkeeping
Should Law Firms Outsource their Bookkeeping
 
wagamamaLab presentation @MIT 20240509 IRODORI
wagamamaLab presentation @MIT 20240509 IRODORIwagamamaLab presentation @MIT 20240509 IRODORI
wagamamaLab presentation @MIT 20240509 IRODORI
 
Beyond Numbers A Holistic Approach to Forensic Accounting
Beyond Numbers A Holistic Approach to Forensic AccountingBeyond Numbers A Holistic Approach to Forensic Accounting
Beyond Numbers A Holistic Approach to Forensic Accounting
 
The Art of Decision-Making: Navigating Complexity and Uncertainty
The Art of Decision-Making: Navigating Complexity and UncertaintyThe Art of Decision-Making: Navigating Complexity and Uncertainty
The Art of Decision-Making: Navigating Complexity and Uncertainty
 
HAL Financial Performance Analysis and Future Prospects
HAL Financial Performance Analysis and Future ProspectsHAL Financial Performance Analysis and Future Prospects
HAL Financial Performance Analysis and Future Prospects
 
NewBase 17 May 2024 Energy News issue - 1725 by Khaled Al Awadi_compresse...
NewBase   17 May  2024  Energy News issue - 1725 by Khaled Al Awadi_compresse...NewBase   17 May  2024  Energy News issue - 1725 by Khaled Al Awadi_compresse...
NewBase 17 May 2024 Energy News issue - 1725 by Khaled Al Awadi_compresse...
 
A BUSINESS PROPOSAL FOR SLAUGHTER HOUSE WASTE MANAGEMENT IN MYSORE MUNICIPAL ...
A BUSINESS PROPOSAL FOR SLAUGHTER HOUSE WASTE MANAGEMENT IN MYSORE MUNICIPAL ...A BUSINESS PROPOSAL FOR SLAUGHTER HOUSE WASTE MANAGEMENT IN MYSORE MUNICIPAL ...
A BUSINESS PROPOSAL FOR SLAUGHTER HOUSE WASTE MANAGEMENT IN MYSORE MUNICIPAL ...
 
Pay after result spell caster (,$+27834335081)@ bring back lost lover same da...
Pay after result spell caster (,$+27834335081)@ bring back lost lover same da...Pay after result spell caster (,$+27834335081)@ bring back lost lover same da...
Pay after result spell caster (,$+27834335081)@ bring back lost lover same da...
 
Unlocking Growth The Power of Outsourcing for CPA Firms
Unlocking Growth The Power of Outsourcing for CPA FirmsUnlocking Growth The Power of Outsourcing for CPA Firms
Unlocking Growth The Power of Outsourcing for CPA Firms
 
Space Tech Expo Exhibitor List 2024 - Exhibitors Data
Space Tech Expo Exhibitor List 2024 - Exhibitors DataSpace Tech Expo Exhibitor List 2024 - Exhibitors Data
Space Tech Expo Exhibitor List 2024 - Exhibitors Data
 
The Vietnam Believer Newsletter_May 13th, 2024_ENVol. 007.pdf
The Vietnam Believer Newsletter_May 13th, 2024_ENVol. 007.pdfThe Vietnam Believer Newsletter_May 13th, 2024_ENVol. 007.pdf
The Vietnam Believer Newsletter_May 13th, 2024_ENVol. 007.pdf
 
Sex service available my WhatsApp number 7374088497
Sex service available my WhatsApp number 7374088497Sex service available my WhatsApp number 7374088497
Sex service available my WhatsApp number 7374088497
 
Navigating Tax Season with Confidence Streamlines CPA Firms
Navigating Tax Season with Confidence Streamlines CPA FirmsNavigating Tax Season with Confidence Streamlines CPA Firms
Navigating Tax Season with Confidence Streamlines CPA Firms
 
SCI9-Q4-MOD8.1.pdfjttstwjwetw55k5wwtwrjw
SCI9-Q4-MOD8.1.pdfjttstwjwetw55k5wwtwrjwSCI9-Q4-MOD8.1.pdfjttstwjwetw55k5wwtwrjw
SCI9-Q4-MOD8.1.pdfjttstwjwetw55k5wwtwrjw
 
How Bookkeeping helps you in Cost Saving, Tax Saving and Smooth Business Runn...
How Bookkeeping helps you in Cost Saving, Tax Saving and Smooth Business Runn...How Bookkeeping helps you in Cost Saving, Tax Saving and Smooth Business Runn...
How Bookkeeping helps you in Cost Saving, Tax Saving and Smooth Business Runn...
 
Most Visionary Leaders in Cloud Revolution, Shaping Tech’s Next Era - 2024 (2...
Most Visionary Leaders in Cloud Revolution, Shaping Tech’s Next Era - 2024 (2...Most Visionary Leaders in Cloud Revolution, Shaping Tech’s Next Era - 2024 (2...
Most Visionary Leaders in Cloud Revolution, Shaping Tech’s Next Era - 2024 (2...
 

Ibis + Substrait.pdf

  • 1. Presented by: Ibis and Substrait: Standardized Analytics 06/23/2022 Hussain Sultan
  • 2. 2 Ibis produces Expressions or Strings for execution on SQL backends t.groupby('region') .aggregate(topk=t.funding_rounds.count()) .sort_by(ibis.desc('topk')) .head() Produces SELECT region ,count(funding_rounds) AS topk FROM companies GROUP BY region ORDER BY topk SQL Strings generated for Execution Engine SQL Backends <sqlalchemy.sql.selectable.S elect object> SQLAlchemy Expression
  • 3. 3 String Execution Backend Ibis API Operations Compile SQL String Backend Specific SQL Flavor and Support Type Check and Optimize Rewrite Build Ibis Expression
  • 4. 4 Expression Generating Backends API Operation Compile SA Expression Backend Specific Expressions or SQLAlchemy Type Check and Optimize Rewrite Build Ibis Expression
  • 5. 5 Ibis Backends - LOC SQLAlchemy-based Backends tend to be lower LOC
  • 6. 6 What if Ibis supported 100’s of backends? DB Engines lists 398 Databases in their popularity ranking https://db-engines.com/en/ranking
  • 7. 7 Substrait: Serialized Relational Algebra substrait views ibis python r scala babel sql presto sql dplyr Producers Consumers ibis
  • 8. 8 Substrait: Serialized Relational Algebra Plan Relations Types i8 i32 fp32 struct Expressions Functions add rank join agg filter read case literal Serialization protobuf text ● Types ● Expressions ● Functions ● Relations ● Plans ● Serialization formats
  • 10. 10 Ibis-substrait producer is actively being developed SQL String Python Expression Under Development Ibis API Compile Substrait Producer
  • 12. 12 Takeaways ● Ibis as a substrait producer, decouples the execution engines and expression building ● Check out Gil Forsyth’s gist that explains the duckdb and ibis substrait integration: https://gist.github.com/gforsyth/496d680e1e29f0876df937e e5091e1b8
  • 14. 14 2. What if we want to consume any SQL DSL into Ibis expressions? API Ops DSL Execute
  • 15. 15 Ibis support multiple execution paradigms SQL String Python Expression Direct Execution Focus of Today’s Talk 1 Ibis API 2 Compile