Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Python 3.7 in r-script #31

Closed
schrags opened this issue Apr 11, 2019 · 4 comments
Closed

Python 3.7 in r-script #31

schrags opened this issue Apr 11, 2019 · 4 comments

Comments

@schrags
Copy link

schrags commented Apr 11, 2019

Has anyone tried using reticulate inside of an r-script executed through rbridge to run a python script that requires python 3.7? I can execute the script fine manually but when it's run through the geoprocessing task it seems to ignore my python configuration line and tries to run it under 2.x and errors out.

use_python('C:\Program Files\Python37\python.exe') is the line of code i'm using at the top of the R script right after the reticulate require. Somehow this doesn't work when it's executed through rbridge. Is there another way to specify a python version?

@dpavlushko
Copy link
Contributor

ArcGIS host Python interpreter. Thus, tool_exec() cannot change already loaded Python.

@schrags
Copy link
Author

schrags commented Apr 12, 2019

That makes sense. It seems as if there is no way to use python packages that require 3.5+ with ArcGIS server for windows geoprocessing?

@scdub
Copy link

scdub commented Apr 12, 2019

You should be able to -- Server includes two separate installations of Python: one for driving the 10.x environment (Python 2.7), and a separate install for the Pro runtime in server. There is some basic documentation in the Server documentation which should get you started. If you connect to that instance, it'll be running on Python 3.6, and you can use conda to augment the availability of additional packages.

@scdub
Copy link

scdub commented Jan 31, 2020

@schrags Closing this issue for inactivity, but if you do need any further advice about working with R and Python 3.x, let us know.

@scdub scdub closed this as completed Jan 31, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants