I have a genetics research background so apologies if this question is too general/lacks software development understanding. Any guidance at all is appreciated.
I have an R package (https://github.com/ZikunY/CARMA) that I would like to implement in python. I've seen that I could potentially take the c++ code in this repo and lift that over to run in python and then rebuild the functions in python.
Am I along the right lines to be approaching this with setuptools, making a setup.py file that ties the c++ code already created with python functions that would match their R equivalent functions? Or am I missing steps and potentially underestimating the task?
For example, at the moment I've just been starting with trying to get one cpp script working in python (although this gives an error):
import pybind11
from setuptools import setup, Extension
ext_modules = [
Extension(
'package',
sources=['sigma.cpp'],
include_dirs=[pybind11.get_include()],
language='c++'
),
]
setup(
name='package',
ext_modules=ext_modules,
install_requires=['pybind11'],
zip_safe=False,
)
AttributeError: 'tuple' object has no attribute 'tb_frame'
from How to convert an R package into Python with c++ compilation?
No comments:
Post a Comment