https://github.com/ranjanan/arcpy.jl
Julia wrapper for the arcpy python package
https://github.com/ranjanan/arcpy.jl
arcpy
Last synced: 5 months ago
JSON representation
Julia wrapper for the arcpy python package
- Host: GitHub
- URL: https://github.com/ranjanan/arcpy.jl
- Owner: ranjanan
- License: other
- Created: 2018-05-26T14:18:05.000Z (about 8 years ago)
- Default Branch: master
- Last Pushed: 2021-02-22T20:00:54.000Z (over 5 years ago)
- Last Synced: 2025-08-26T07:27:29.886Z (10 months ago)
- Topics: arcpy
- Language: Julia
- Homepage:
- Size: 6.84 KB
- Stars: 1
- Watchers: 1
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# Arcpy.jl
[](https://travis-ci.org/ranjanan/Arcpy.jl) [](https://coveralls.io/github/ranjanan/Arcpy.jl?branch=master) [](http://codecov.io/github/ranjanan/Arcpy.jl?branch=master)
`Arcpy.jl` is a Julia wrapper around ESRI's [`arcpy` python package](http://pro.arcgis.com/en/pro-app/arcpy/get-started/what-is-arcpy-.htm).
**Please note that you need an ArcGIS license for this package to work.**
## Why use this wrapper?
This wrapper allows users of [`Circuitscape.jl`](https://github.com/Circuitscape/Circuitscape.jl) to interface
with `arcpy` while staying within the Julia environment and taking advantage of its parallel computing abilities.
## Setup and Installation
1. Make sure you have [ArcGIS](http://arcgis.com) installed on your system. Note that it works only on Windows.
2. Open Julia. Run:
```julia
Pkg.clone("https://github.com/ranjanan/Arcpy.jl")
```
3. Now we need Julia to point to the python executable shipped with your copy of ArcGIS. To do that, do:
```julia
ENV["PYTHON"] = "/path/to/arcgis/python"
Pkg.build("Arcpy")
```
If all goes well, you should see a message from Julia that `PyCall` is now linked to your ArcGIS's python, and
```julia
using Arcpy
```
should just work.
## Usage
If you have `arcpy` python code that looks like:
```python
import arcpy # loads python package
arcpy.some_arcpy_function(args...)
```
the corresponding Julia code should look like:
```julia
using Arcpy
Arcpy.some_arcpy_function(args...)
```
with a small number of excpetions, such as
```python
arcpy.env.workspace = "some/workspace"
```
should be written as
```julia
Arcpy.setenv(:workspace, "some/workspace")
```
Since `arcpy` has hundreds of functions, it is possible that not everything is wrapped. If you would like a particular wrapped, please [open an issue](https://github.com/ranjanan/Arcpy.jl/issues).