跳到主要导航 跳到搜索 跳到主要内容

Assessing and Restoring Reproducibility of Jupyter Notebooks

  • Jiawei Wang
  • , Tzu Yang Kuo
  • , Li Li*
  • , Andreas Zeller
  • *此作品的通讯作者
  • Monash University
  • Hong Kong University of Science and Technology
  • Helmholtz Center for Information Security

科研成果: 书/报告/会议事项章节会议稿件同行评审

摘要

Jupyter notebooks-documents that contain live code, equations, visualizations, and narrative text-now are among the most popular means to compute, present, discuss and disseminate scientific findings. In principle, Jupyter notebooks should easily allow to reproduce and extend scientific computations and their findings; but in practice, this is not the case. The individual code cells in Jupyter notebooks can be executed in any order, with identifier usages preceding their definitions and results preceding their computations. In a sample of 936 published notebooks that would be executable in principle, we found that 73% of them would not be reproducible with straightforward approaches, requiring humans to infer (and often guess) the order in which the authors created the cells. In this paper, we present an approach to (1) automatically satisfy dependencies between code cells to reconstruct possible execution orders of the cells; and (2) instrument code cells to mitigate the impact of non-reproducible statements (i.e., random functions) in Jupyter notebooks. Our Osiris prototype takes a notebook as input and outputs the possible execution schemes that reproduce the exact notebook results. In our sample, Osiris was able to reconstruct such schemes for 82.23% of all executable notebooks, which has more than three times better than the state-of-the-art; the resulting reordered code is valid program code and thus available for further testing and analysis.

源语言英语
主期刊名Proceedings - 2020 35th IEEE/ACM International Conference on Automated Software Engineering, ASE 2020
出版商Institute of Electrical and Electronics Engineers Inc.
138-149
页数12
ISBN(电子版)9781450367684
DOI
出版状态已出版 - 9月 2020
已对外发布
活动35th IEEE/ACM International Conference on Automated Software Engineering, ASE 2020 - Virtual, Online, 澳大利亚
期限: 22 9月 202025 9月 2020

出版系列

姓名Proceedings - 2020 35th IEEE/ACM International Conference on Automated Software Engineering, ASE 2020

会议

会议35th IEEE/ACM International Conference on Automated Software Engineering, ASE 2020
国家/地区澳大利亚
Virtual, Online
时期22/09/2025/09/20

学术指纹

探究 'Assessing and Restoring Reproducibility of Jupyter Notebooks' 的科研主题。它们共同构成独一无二的学术指纹。

引用此