Installing pyjulia
还没有人认领这个 Issue。
评估
调研方向
首先定位 setup.py,并检查 issue 中展示的 julia.install() 和 LibJulia 入口点,同时将链接的 juliacall 示例作为行为参考。当用户可以调用建议的 setup_pyjulia_env 流程来安装所需的 Julia 依赖项,并可选择实例化请求的项目环境时,即视为完成。
由索引模型根据 Issue 内容生成。
描述
Here is a little function that downloads julia if needed, set up an environmnt and instantiate the project.
I think something similar should be provided so that users can call it in setup.py
def setup_pyjulia_env(path_to_project="."):
"""
A function that installs all dependencies for current environment.
This should be the same as what `juliacall` does at every import time.
* `path_to_project` is the path to the project that will be instantiated.
If `None`, no project will be instantiated. Defaults: to the current
working directory.
"""
import jill.install # noqa: autoimport
import os # noqa: autoimport
import shutil # noqa: autoimport
if shutil.which('julia') is None:
print(
"No Julia executable found, installing the latest version using `jill`")
jill.install.install_julia("stable", confirm=True)
if shutil.which('julia') is None:
print(f"Please add {os.environ['JILL_SYMLINK_DIR']} to your path")
import julia # noqa: autoimport
# the following installs dependencies for pyjulia
julia.install()
from julia.api import LibJulia # noqa: autoimport
if path_to_project is not None:
api = LibJulia.load()
api.init_julia([f"--project={path_to_project}"])
from julia import Main # noqa: autoimport
Main.eval('using Pkg')
Main.eval('Pkg.instantiate()')
Example from: https://github.com/00sapo/pyjulia-vs-juliacall
- 主要语言
- Python
- 星标
- 893
- 派生
- 101
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
JuliaPy/pyjulia 的其他 Issue
-
难度 4/5 3-5 天 新手友好度 25/100
-
难度 4/5 3-5 天 新手友好度 25/100
-
难度 4/5 3-5 天 新手友好度 20/100
-
难度 3/5 1-2 天 新手友好度 48/100
-
难度 5/5 一周以上 新手友好度 25/100
相似的 Issue
-
kind/bug priority/medium qa_automation
难度 2/5 1-3 小时 新手友好度 78/100
yugabyte/yugabyte-db#37324 ·
维护者通常 1 天内回复
-
good first issue
难度 1/5 1 小时以内 新手友好度 87/100
btclib-org/btclib-node#2260 ·
维护者通常 1 天内回复
-
ChatBedrockConverse changes the keys of JSON tool results to camelCase (`order_id` becomes `orderId`)可能已有人在做 @geyazheng 今天认领。 未关闭
难度 2/5 1-3 小时 新手友好度 78/100
langchain-ai/langchain-aws#1469 ·
维护者通常 1 天内回复
-
GCToggler leaves collection enabled if the body re-enables it可能已有人在做 @Gambit-Checkmate 今天认领。 未关闭
难度 2/5 1-3 小时 新手友好度 76/100
维护者通常 7 天内回复
-
难度 1/5 1 小时以内 新手友好度 88/100
维护者通常 1 天内回复