State Key Laboratory of Magnetic Resonance and Atomic and Molecular Physics, Wuhan Center for Magnetic Resonance, Wuhan Institute of Physics and Mathematics, Innovation Academy for Precision Measurement Science and Technology, Chinese Academy of Sciences, Wuhan, 430071, People's Republic of China.
Zhongke-Niujin MR Tech Co. Ltd, Wuhan, 430075, People's Republic of China.
BMC Bioinformatics. 2021 Dec 7;22(1):581. doi: 10.1186/s12859-021-04492-y.
Software for nuclear magnetic resonance (NMR) spectrometers offer general functionality of instrument control and data processing; these applications are often developed with non-scripting languages. NMR users need to flexibly integrate rapidly developing NMR applications with emerging technologies. Scripting systems offer open environments for NMR users to write custom programs. However, existing scripting systems have limited capabilities for both extending the functionality of NMR software's non-script main program and using advanced native script libraries to support specialized application domains (e.g., biomacromolecules and metabolomics). Therefore, it is essential to design a novel scripting system to address both of these needs.
Here, a novel NMR scripting system named SpinSPJ is proposed. It works as a plug-in in the Java based NMR spectrometer software SpinStudioJ. In the scripting system, both Java based NMR methods and original CPython based libraries are supported. A module has been developed as a bridge to integrate the runtime environments of Java and CPython. The module works as an extension in the CPython environment and interacts with Java via the Java Native Interface. Leveraging this bridge, Java based instrument control and data processing methods of SpinStudioJ can be called with the CPython style. Compared with traditional scripting systems, SpinSPJ better supports both extending the non-script main program and implementing advanced NMR applications with a rich variety of script libraries. NMR researchers can easily call functions of instrument control and data processing as well as developing complex functionality (such as multivariate statistical analysis, deep learning, etc.) with CPython native libraries.
SpinSPJ offers a user-friendly environment to implement custom functionality leveraging its powerful basic NMR and rich CPython libraries. NMR applications with emerging technologies can be easily integrated. The scripting system is free of charge and can be downloaded by visiting http://www.spinstudioj.net/spinspj .
核磁共振(NMR)光谱仪的软件提供了仪器控制和数据处理的通用功能;这些应用程序通常是使用非脚本语言开发的。NMR 用户需要灵活地将快速发展的 NMR 应用程序与新兴技术集成。脚本系统为 NMR 用户提供了一个开放的环境,可以编写自定义程序。然而,现有的脚本系统在扩展 NMR 软件非脚本主程序的功能和使用高级本机脚本库来支持专门的应用领域(例如,生物大分子和代谢组学)方面的能力有限。因此,设计一个新的脚本系统来满足这两个需求是至关重要的。
这里提出了一个名为 SpinSPJ 的新型 NMR 脚本系统。它作为基于 Java 的 NMR 光谱仪软件 SpinStudioJ 的插件运行。在脚本系统中,既支持基于 Java 的 NMR 方法,也支持原始的基于 CPython 的库。已经开发了一个模块作为桥接,以集成 Java 和 CPython 的运行时环境。该模块作为 CPython 环境中的扩展,并通过 Java 本地接口与 Java 交互。利用这个桥接,SpinStudioJ 的基于 Java 的仪器控制和数据处理方法可以用 CPython 风格调用。与传统的脚本系统相比,SpinSPJ 更好地支持扩展非脚本主程序和使用各种脚本库实现高级 NMR 应用程序。NMR 研究人员可以轻松地调用仪器控制和数据处理的功能,并使用 CPython 本机库开发复杂的功能(例如,多元统计分析、深度学习等)。
SpinSPJ 提供了一个用户友好的环境,可以利用其强大的基本 NMR 和丰富的 CPython 库实现自定义功能。新兴技术的 NMR 应用程序可以很容易地集成。该脚本系统是免费的,可以通过访问 http://www.spinstudioj.net/spinspj 下载。