Group Group Group Group Group Group Group Group Group

Help with PythonKit or if you have a better idea

Do you guys have a tutorial on working with python in Xcode, https://www.google.com/url?sa=t&rct=j&q=&esrc=s&source=web&cd=&cad=rja&uact=8&ved=2ahUKEwiQgtu-zZD1AhXslWoFHRDdAe8QwqsBegQIAhAB&url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3Dp64f6befZkw&usg=AOvVaw0SDvCLwXROS5_HS0zcVBIr . Here is the lib GitHub - pvieito/PythonKit: Swift framework to interact with Python. . The reason im wanting this is for the reason Chris Lattner started it, I think you most likely know who he is. Also I believe you guys had some tutorial that I built a trading program in and im not able to find that again. I guess it wasn’t here but I could have sworn it was. Im looking for libs like Matplotlib, Numpy and panda. Or if you have a better idea then mine, im all ears. I was simply thinking this could cut a ton of time off because the libs are already made in C and easily transferred over with python, PythonKit. I am just basically wondering how to access the python kit from Xcode. Also all sign back up and everything but do you have a slack instead of email?

the question I have is wether this will work or not using swift? The end goal of all this is to run python within swift so I can use to frameworks like Numpy, pandas, Matplotlib. I am trying to get this stuff understood so I can use Xcode to its fullest wile using swift. The libraries im going for may not be the best way, fastest way, im all ears for suggestions.

please define the proper way to go about my question lol. As you can see im all over the place looking for something that will fill the void of Numpy/pandas/matplotlib or how to work with those within swift as Chris(first video) was doing. Simply I am looking for a fast, lightweight algos like you have with those three. im going to continue on the data structures thing, im understanding a shit ton more then I did in the being, thanks to py.

PY and swift have a lot of similarities. I understand so much more about the full scope of swift rather than the limited area I started. Still have a shit ton more to learn though, ty for your help.


Also it says I need Xcode 10.1 in order to open the project, have it work. I don’t mind getting a different version of Xcode I just need to get things working all in sync.

Also I have this working from the GitHub folder but having issues with importing this to a project so its all in one area. Think that’s not going to work

Sorry guys just trying to get Xcode all figured out.

n swift 5 you can try PythonKit framework.

Here’s example of the usage:

import PythonKit

let sys = try Python.import("sys")

print("Python \(sys.version_info.major).\(sys.version_info.minor)")
print("Python Version: \(sys.version)")
print("Python Encoding: \(sys.getdefaultencoding().upper())")