Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/rurlus/mmmu
Minimal Model Metric Uncertainty
https://github.com/rurlus/mmmu
Last synced: 5 days ago
JSON representation
Minimal Model Metric Uncertainty
- Host: GitHub
- URL: https://github.com/rurlus/mmmu
- Owner: RUrlus
- License: apache-2.0
- Created: 2023-01-13T10:07:58.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2024-02-19T19:22:38.000Z (10 months ago)
- Last Synced: 2024-10-30T23:17:18.870Z (about 2 months ago)
- Language: C++
- Size: 41 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# mmu
This package was generated by `pyxt` to facilitate easy developments of C++ extesions (Pybind11) for Python.
All the boilerplate around CMake and compilation has been handled for you.## The basics
The package name is `mmu`.
The compiled extension is named `_mmu_core`.You can access the extension using `mmu.core` which is an alias for `mmu.lib._mmu_core` where the extension is stored.
## Installing the package
The package can be installed as normal using:
`pip install .`
## Code
All code in located in the `src` directory.
The directory structure follows the conventions for their respective languages.
Python code lives under `src/mmu`.
C++ code is placed `src/mmu-core/src` and `src/mmu-core/include/mmu`.### Adding C++ functions
If you are adding a C++ function you have to follow these steps:
1. write implementation, e.g. `add` in `src/mmu-core/src/main.cpp`
2. write a binding function, e.g. `bind_add` in `src/mmu-core/src/main.cpp`
3. add the signatures to the corresponding header file, e.g. `add` and `bind_add` in `src/mmu-core/include/mmu/main.hpp`
4. add a call to the binding function, e.g. as `bind_add` in `src/mmu-core/src/bindings.cpp`
5. re-install packageSee [Pybind11 docs](https://pybind11.readthedocs.io/en/stable/) for details on their package.
You can set the build-type in the `pyproject.toml`.