Shamrock 2025.10.0
Astrophysical Code
Loading...
Searching...
No Matches
start_python.hpp
Go to the documentation of this file.
1// -------------------------------------------------------//
2//
3// SHAMROCK code for hydrodynamics
4// Copyright (c) 2021-2026 Timothée David--Cléris <tim.shamrock@proton.me>
5// SPDX-License-Identifier: CeCILL Free Software License Agreement v2.1
6// Shamrock is licensed under the CeCILL 2.1 License, see LICENSE for more information
7//
8// -------------------------------------------------------//
9
10#pragma once
11
19#include <string>
20
21namespace shambindings {
22
28 void setpypath(std::string path);
29
35 void set_sys_argv(int argc, char *argv[]);
36
42 void setpypath_from_binary(std::string binary_path);
43
52 void start_ipython(bool do_print, int argc, char *argv[]);
53
62 void run_py_file(std::string file_path, bool do_print, int argc, char *argv[]);
63
69 void modify_py_sys_path(bool do_print);
70
71} // namespace shambindings
void setpypath_from_binary(std::string binary_path)
set the value of sys.path before init from the supplied binary
void start_ipython(bool do_print, int argc, char *argv[])
Start shamrock embded ipython interpreter.
void modify_py_sys_path(bool do_print)
Modify Python sys.path to point to one detected during cmake invocation.
void set_sys_argv(int argc, char *argv[])
set the value of sys.argv
void setpypath(std::string path)
set the value of sys.path before init
void run_py_file(std::string file_path, bool do_print, int argc, char *argv[])
run python runscript