Due to the long runtime of Data Science (DS) pipelines, even small programming mistakes can be very costly, if they are not detected statically. However, even basic static type checking of DS pipelines is difficult because most are written in Python. Static typing is available in Python only via external linters. These require static type annotations for parameters or results of functions, which many DS libraries do not provide. In this paper, we show how the wealth of Python DS libraries can be used in a statically safe way via Safe-DS, a domain specific language (DSL) for DS. Safe-DS catches conventional type errors plus errors related to range restrictions, data manipulation, and call order of functions, going well beyond the abilities of current Python linters. Python libraries are integrated into Safe-DS via a stub language for specifying the interface of its declarations, and an API-Editor that is able to extract type information from the code and documentation of Python libraries, and automatically generate suitable stubs. Moreover, Safe-DS complements textual DS pipelines with a graphical representation that eases safe development by preventing syntax errors. The seamless synchronization of textual and graphic view lets developers always choose the one best suited for their skills and current task. We think that Safe-DS can make DS development easier, faster, and more reliable, significantly reducing development costs.


翻译:由于数据科学管线的运行时间长,即使是微小的编程错误若未能被静态检测,也可能导致高昂成本。然而,数据科学管线大多使用Python编写,因此对其实现基本的静态类型检查本身就存在困难。Python仅能通过外部链接器实现静态类型,但这些需要函数参数或结果的静态类型注解,而许多数据科学库并未提供此类注解。本文展示了如何通过面向数据科学的领域特定语言Safe-DS,以静态安全的方式利用丰富的Python数据科学库。Safe-DS不仅能捕获常规类型错误,还能检测与范围限制、数据操作及函数调用顺序相关的错误,其能力远超现有Python链接器。Safe-DS通过存根语言定义声明的接口,并借助API编辑器从Python库的代码和文档中提取类型信息、自动生成合适的存根,从而实现对Python库的集成。此外,Safe-DS用图形化表示补充文本式数据科学管线,通过防止语法错误来提升开发安全性。文本视图与图形视图的无缝同步使开发者能够根据自身技能和当前任务灵活选择最适模式。我们认为Safe-DS能够使数据科学开发更简单、更快速、更可靠,显著降低开发成本。

0
下载
关闭预览

相关内容

DirectShow是一种由微软公司开发的能够让软件开发者对媒体文件执行各种不同处理的应用程序设计接口。
【2022新书】Python数据分析第三版,579页pdf
专知会员服务
255+阅读 · 2022年8月31日
【2022新书】Python DevOps,245页pdf
专知会员服务
91+阅读 · 2022年7月11日
【实用书】Python数据分析手册,437页pdf带你实战数据清洗
专知会员服务
19+阅读 · 2020年9月6日
【2020新书】实战R语言4,323页pdf
专知会员服务
103+阅读 · 2020年7月1日
【2022新书】Python数据分析第三版,579页pdf
专知
19+阅读 · 2022年8月31日
VCIP 2022 Call for Demos
CCF多媒体专委会
1+阅读 · 2022年6月6日
Sreg 一款社工小工具
黑白之道
13+阅读 · 2019年8月18日
Transferring Knowledge across Learning Processes
CreateAMind
29+阅读 · 2019年5月18日
Unsupervised Learning via Meta-Learning
CreateAMind
44+阅读 · 2019年1月3日
A Technical Overview of AI & ML in 2018 & Trends for 2019
待字闺中
18+阅读 · 2018年12月24日
【推荐】免费书(草稿):数据科学的数学基础
机器学习研究会
20+阅读 · 2017年10月1日
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
1+阅读 · 2013年12月31日
国家自然科学基金
0+阅读 · 2013年12月31日
国家自然科学基金
0+阅读 · 2012年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
国家自然科学基金
0+阅读 · 2008年12月31日
Directions for Explainable Knowledge-Enabled Systems
Arxiv
26+阅读 · 2020年3月17日
VIP会员
最新内容
BES:让语言模型通过双向进化搜索自我改进
专知会员服务
3+阅读 · 5月30日
以色列-美国-伊朗战争中的无人机:关键要点
专知会员服务
4+阅读 · 5月30日
《Palantir任务保障性软件安全标准(MA-S2)》
专知会员服务
10+阅读 · 5月30日
基于声学的无人机检测技术综述
专知会员服务
8+阅读 · 5月30日
《当代混合战争分析框架:俄乌战争经验教训》
战略前沿人工智能的再思考(中文)
专知会员服务
8+阅读 · 5月29日
《量化地基防空系统间接效应的博弈论方法》
专知会员服务
6+阅读 · 5月29日
相关VIP内容
【2022新书】Python数据分析第三版,579页pdf
专知会员服务
255+阅读 · 2022年8月31日
【2022新书】Python DevOps,245页pdf
专知会员服务
91+阅读 · 2022年7月11日
【实用书】Python数据分析手册,437页pdf带你实战数据清洗
专知会员服务
19+阅读 · 2020年9月6日
【2020新书】实战R语言4,323页pdf
专知会员服务
103+阅读 · 2020年7月1日
相关资讯
【2022新书】Python数据分析第三版,579页pdf
专知
19+阅读 · 2022年8月31日
VCIP 2022 Call for Demos
CCF多媒体专委会
1+阅读 · 2022年6月6日
Sreg 一款社工小工具
黑白之道
13+阅读 · 2019年8月18日
Transferring Knowledge across Learning Processes
CreateAMind
29+阅读 · 2019年5月18日
Unsupervised Learning via Meta-Learning
CreateAMind
44+阅读 · 2019年1月3日
A Technical Overview of AI & ML in 2018 & Trends for 2019
待字闺中
18+阅读 · 2018年12月24日
【推荐】免费书(草稿):数据科学的数学基础
机器学习研究会
20+阅读 · 2017年10月1日
相关基金
国家自然科学基金
2+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
1+阅读 · 2013年12月31日
国家自然科学基金
0+阅读 · 2013年12月31日
国家自然科学基金
0+阅读 · 2012年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
国家自然科学基金
0+阅读 · 2008年12月31日
Top
微信扫码咨询专知VIP会员