xeus-cling
所属分类:C/C++基础
开发工具:C++
文件大小:2225KB
下载次数:0
上传日期:2023-04-12 08:56:19
上 传 者:
sh-1993
说明: C++编程语言的Jupyter内核
(Jupyter kernel for the C++ programming language)
文件列表:
.appveyor.yml (1815, 2023-08-05)
.azure-pipelines (0, 2023-08-05)
.azure-pipelines\azure-pipelines-linux.yml (372, 2023-08-05)
.azure-pipelines\azure-pipelines-osx.yml (693, 2023-08-05)
.azure-pipelines\unix-build.yml (1707, 2023-08-05)
.binder (0, 2023-08-05)
.binder\environment.yml (157, 2023-08-05)
.clang-format (2466, 2023-08-05)
CMakeLists.txt (17890, 2023-08-05)
CONTRIBUTING.md (1193, 2023-08-05)
LICENSE (1500, 2023-08-05)
azure-pipelines.yml (142, 2023-08-05)
binder-logo.svg (3008, 2023-08-05)
docs (0, 2023-08-05)
docs\Doxyfile (325, 2023-08-05)
docs\Makefile (6614, 2023-08-05)
docs\environment.yml (76, 2023-08-05)
docs\make.bat (7285, 2023-08-05)
docs\source (0, 2023-08-05)
docs\source\_static (0, 2023-08-05)
docs\source\_static\main_stylesheet.css (60, 2023-08-05)
docs\source\build_options.rst (1661, 2023-08-05)
docs\source\cmake.svg (17753, 2023-08-05)
docs\source\conda.svg (1805, 2023-08-05)
docs\source\conf.py (841, 2023-08-05)
docs\source\display.png (34039, 2023-08-05)
docs\source\executable.png (24279, 2023-08-05)
docs\source\file_magic.png (16182, 2023-08-05)
docs\source\help.png (60413, 2023-08-05)
docs\source\image.png (153886, 2023-08-05)
docs\source\index.rst (827, 2023-08-05)
docs\source\inline_help.rst (2614, 2023-08-05)
docs\source\installation.rst (2003, 2023-08-05)
docs\source\magics.rst (2895, 2023-08-05)
docs\source\rich_display.rst (3828, 2023-08-05)
docs\source\timeit_magic.png (36072, 2023-08-05)
docs\source\xeus-cling.svg (4592, 2023-08-05)
... ...
# ![xeus-cling](https://github.com/jupyter-xeus/xeus-cling/blob/master/docs/source/xeus-cling.svg)
[![Azure Pipelines](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://dev.azure.com/jupyter-xeus/jupyter-xeus/_apis/build/status/jupyter-xeus.xeus-cling?branchName=master)](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://dev.azure.com/jupyter-xeus/jupyter-xeus/_build/latest?definitionId=4&branchName=master)
[![Appveyor](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://ci.appveyor.com/api/projects/status/qn0wskxlvy52utuv?svg=true)](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://ci.appveyor.com/project/jupyter-xeus/xeus-cling)
[![Documentation Status](https://github.com/jupyter-xeus/xeus-cling/blob/master/http://readthedocs.org/projects/xeus-cling/badge/?version=latest)](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://xeus-cling.readthedocs.io/en/latest/?badge=latest)
[![Binder](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://img.shields.io/badge/launch-binder-brightgreen.svg)](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://mybinder.org/v2/gh/jupyter-xeus/xeus-cling/stable?filepath=notebooks/xcpp.ipynb)
[![Join the Gitter Chat](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://badges.gitter.im/Join%20Chat.svg)](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://gitter.im/QuantStack/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
`xeus-cling` is a Jupyter kernel for C++ based on the C++ interpreter [cling](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://github.com/root-project/cling) and
the native implementation of the Jupyter protocol [xeus](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://github.com/jupyter-xeus/xeus).
## Installation
xeus-cling has been packaged for the mamba (or conda) package manager on the **Linux** and **OS X** platforms. At the moment, we are not providing packages for the **Windows** platform.
To ensure that the installation works, it is preferable to install `xeus-cling` in a fresh environment. It is also needed to use a [miniforge](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://github.com/conda-forge/miniforge) or [miniconda](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://conda.io/miniconda.html) installation because with the full [anaconda](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://www.anaconda.com/) you may have a conflict with the `ZeroMQ` library which is already installed in the anaconda distribution.
### Installation with mamba or conda
The safest usage is to create an environment named `cling`:
```
mamba create -n cling
source activate cling
```
Then you can install in this environment `xeus-cling` and its dependencies
```
mamba install xeus-cling -c conda-forge
```
### Installation from source
You will first need to create a new environment and install the dependencies:
```bash
mamba create -n xeus-cling -c conda-forge cmake xeus-zmq cling nlohmann_json cppzmq xtl pugixml doctest cpp-argparse
source activate xeus-cling
```
Please refer to [environment-host.yml](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://github.com/jupyter-xeus/xeus-cling/blob/main/environment-host.yml) for packages specific versions to install if applicable.
You can then compile the sources. From the build directory, run:
```bash
cmake -D CMAKE_INSTALL_PREFIX=${CONDA_PREFIX} -D CMAKE_C_COMPILER=$CC -D CMAKE_CXX_COMPILER=$CXX -D CMAKE_INSTALL_LIBDIR=${CONDA_PREFIX}/lib ..
make && make install
```
If you don't have a frontend already installed (classic Jupyter Notebook or JupyterLab for instance), install one:
```bash
mamba install jupyterlab -c conda-forge
```
## Trying it online
To try out xeus-cling interactively in your web browser, just click on the binder
link:
[![Binder](https://github.com/jupyter-xeus/xeus-cling/blob/master/binder-logo.svg)](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://mybinder.org/v2/gh/jupyter-xeus/xeus-cling/stable?filepath=notebooks/xcpp.ipynb)
## Documentation
To get started with using `xeus-cling`, check out the full documentation
http://xeus-cling.readthedocs.io/
## Usage
Launch the jupyter notebook with `jupyter notebook` and launch a new C++ notebook by selecting the **C++17** kernel in the *new* dropdown.
### A C++ notebook
You can now make use of the C++ programming language in the Jupyter notebook.
![A C++ notebook](https://github.com/jupyter-xeus/xeus-cling/blob/master/notebook.png)
### Inline help and tab-completion
Quick help is shown on the pager with the special `?` magic.
![Help](https://github.com/jupyter-xeus/xeus-cling/blob/master/help.png)
Content for the quick help is available for the standard library, and can be made available for third-party packages.
### Rendering of rich outputs
![Rich output](https://github.com/jupyter-xeus/xeus-cling/blob/master/rich-output.png)
### Jupyter interactive widgets
A C++ backend for the Jupyter interactive widgets is available in the [`xwidgets`](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://github.com/jupyter-xeus/xwidgets/) package.
![Widgets](https://github.com/jupyter-xeus/xeus-cling/blob/master/widgets.gif)
## Dependencies
``xeus-cling`` depends on
- [xeus-zmq](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://github.com/jupyter-xeus/xeus-zmq)
- [xtl](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://github.com/xtensor-stack/xtl)
- [cling](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://github.com/root-project/cling)
- [pugixml](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://github.com/zeux/pugixml)
- [cpp-argparse](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://github.com/p-ranav/argparse)
- [nlohmann_json](https://github.com/jupyter-xeus/xeus-cling/blob/master/https://github.com/nlohmann/json)
| `xeus-cling` | `xeus-zmq` | `xtl` | `cling` | `pugixml` | `cppzmq` | `cpp-argparse`| `nlohmann_json` | `dirent` (windows only) |
|--------------|-----------------|-----------------|---------------|---------------|----------|---------------|-----------------|-------------------------|
| main | >=1.1.0,<2.0.0 | >=0.7.0,<0.8.0 | >=0.9,<0.10 | ~1.8.1 | ~4.3.0 | ~2.9 | >=3.6.1,<4.0 | >=2.3.2,<3 |
| 0.15.3 | >=1.1.0,<2.0.0 | >=0.7.0,<0.8.0 | >=0.9,<0.10 | ~1.8.1 | ~4.3.0 | ~2.9 | >=3.6.1,<4.0 | >=2.3.2,<3 |
| 0.15.2 | >=1.1.0,<2.0.0 | >=0.7.0,<0.8.0 | >=0.9,<0.10 | ~1.8.1 | ~4.3.0 | ~2.9 | >=3.6.1,<4.0 | >=2.3.2,<3 |
| 0.15.1 | >=1.0.0,<2.0.0 | >=0.7.0,<0.8.0 | >=0.9,<0.10 | ~1.8.1 | ~4.3.0 | ~2.9 | >=3.6.1,<4.0 | >=2.3.2,<3 |
| 0.15.0 | >=1.0.0,<2.0.0 | >=0.7.0,<0.8.0 | >=0.9,<0.10 | ~1.8.1 | ~4.3.0 | ~2.9 | >=3.6.1,<4.0 | >=2.3.2,<3 |
Prior to version 0.15, `xeus-cling` was depending on `cxxopts` instead of `cpp-argparse`.
| `xeus-cling` | `xeus-zmq` | `xtl` | `cling` | `pugixml` | `cppzmq` | `cxxopts` | `nlohmann_json` | `dirent` (windows only) |
|--------------|-----------------|-----------------|---------------|---------------|----------|---------------|-----------------|-------------------------|
| 0.14.0 | >=1.0.0,<2.0.0 | >=0.7.0,<0.8.0 | >=0.6,<0.9 | ~1.8.1 | ~4.3.0 | >=2.1.1,<=2.2 | >=3.6.1,<4.0 | >=2.3.2,<3 |
Prior to version 0.14, `xeus-cling` was depending on `xeus` instead of `xeus-zmq`:
| `xeus-cling` | `xeus` | `xtl` | `cling` | `pugixml` | `cppzmq` | `cxxopts` | `nlohmann_json` | `dirent` (windows only) |
|--------------|-----------------|-----------------|---------------|---------------|----------|---------------|-----------------|-------------------------|
| 0.13.0 | >=2.0.0,<3.0.0 | >=0.7.0,<0.8.0 | >=0.6,<0.9 | ~1.8.1 | ~4.3.0 | >=2.1.1,<=2.2 | >=3.6.1,<3.10 | >=2.3.2,<3 |
| 0.12.1 | >=1.0.0,<2.0.0 | >=0.7.0,<0.8.0 | >=0.6,<0.9 | ~1.8.1 | ~4.3.0 | >=2.1.1,<=2.2 | >=3.6.1,<4.0 | >=2.3.2,<3 |
| 0.12.0 | >=1.0.0,<2.0.0 | >=0.7.0,<0.8.0 | >=0.6,<0.9 | ~1.8.1 | ~4.3.0 | >=2.1.1,<=2.2 | >=3.6.1,<4.0 | >=2.3.2,<3 |
`xeus-cling` requires its dependencies to be built with the same compiler and same C runtime as the one used to build `cling`.
## Contributing
See [CONTRIBUTING.md](https://github.com/jupyter-xeus/xeus-cling/blob/master/./CONTRIBUTING.md) to know how to contribute and set up a development environment.
## License
We use a shared copyright model that enables all contributors to maintain the
copyright on their contributions.
This software is licensed under the BSD-3-Clause license. See the [LICENSE](https://github.com/jupyter-xeus/xeus-cling/blob/master/LICENSE) file for details.
近期下载者:
相关文件:
收藏者: