Skip to content

Commit

Permalink
anaconda install included but note building
Browse files Browse the repository at this point in the history
  • Loading branch information
mmann1123 committed Sep 26, 2022
1 parent 3a27f92 commit 4c4bc9e
Show file tree
Hide file tree
Showing 127 changed files with 1,579 additions and 1,642 deletions.
Binary file modified pygis/_build/.doctrees/docs/b_python_by_example.doctree
Binary file not shown.
Binary file modified pygis/_build/.doctrees/docs/c_features.doctree
Binary file not shown.
Binary file modified pygis/_build/.doctrees/docs/c_new_vectors.doctree
Binary file not shown.
Binary file modified pygis/_build/.doctrees/docs/e_buffer_neighbors.doctree
Binary file not shown.
Binary file modified pygis/_build/.doctrees/docs/e_new_rasters.doctree
Binary file not shown.
Binary file modified pygis/_build/.doctrees/docs/e_raster_reproject.doctree
Binary file not shown.
Binary file modified pygis/_build/.doctrees/docs/e_raster_window_operations.doctree
Binary file not shown.
Binary file modified pygis/_build/.doctrees/docs/e_vector_overlay.doctree
Binary file not shown.
Binary file modified pygis/_build/.doctrees/docs/f_rs_config.doctree
Binary file not shown.
Binary file modified pygis/_build/.doctrees/docs/f_rs_io.doctree
Binary file not shown.
Binary file modified pygis/_build/.doctrees/docs/f_rs_ml_predict.doctree
Binary file not shown.
Binary file modified pygis/_build/.doctrees/environment.pickle
Binary file not shown.
Binary file modified pygis/_build/.jupyter_cache/global.db
Binary file not shown.
Binary file modified pygis/_build/html/_images/b_python_by_example_14_0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified pygis/_build/html/_images/b_python_by_example_16_0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified pygis/_build/html/_images/b_python_by_example_34_0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified pygis/_build/html/_images/b_python_by_example_3_0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified pygis/_build/html/_images/c_features_9_0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified pygis/_build/html/_images/e_new_rasters_28_13.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified pygis/_build/html/_images/e_raster_reproject_3_0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified pygis/_build/html/_images/e_raster_window_operations_23_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion pygis/_build/html/_sources/docs/a_intro.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"cells": [
{
"cell_type": "markdown",
"id": "b11ddcdb",
"id": "63d51b94",
"metadata": {},
"source": [
" \n",
Expand Down
2 changes: 1 addition & 1 deletion pygis/_build/html/_sources/docs/b_about_py.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"cells": [
{
"cell_type": "markdown",
"id": "2731d4d2",
"id": "aad2fed9",
"metadata": {},
"source": [
"(b_about_py)=\n",
Expand Down
2 changes: 1 addition & 1 deletion pygis/_build/html/_sources/docs/b_conda_started.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"cells": [
{
"cell_type": "markdown",
"id": "924543a6",
"id": "7f2bff9d",
"metadata": {},
"source": [
"(conda_started)=\n",
Expand Down
54 changes: 54 additions & 0 deletions pygis/_build/html/_sources/docs/b_conda_started.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ html_meta:
----------------

```{admonition} Learning Objectives
- Learn basics of anaconda
- Set up a working environment for spatial modeling
- Learn the basics of Docker
- Pull, run, and update a container set up for spatial modeling
```
Expand All @@ -31,6 +33,58 @@ html_meta:
# Setting up Python for Spatial on Mac, Windows, and Linux
Spatial analysis requires a pretty broad set of python modules and with it, comes a lot of dependencies. And to be honest, the only thing Python doesn't do well with, is dependencies. Luckily we have a few tricks up our sleeves to help you get to work fast.


## Anaconda
### Install Anaconda
Anaconda is a package manager that makes handling dependencies much easier. Before you begin install:

- [Anaconda](https://www.anaconda.com/products/distribution)

Alternatively, if you don't have much free space in your computer (or if think anaconda is bloated- which is ):

- [miniconda](https://conda.io/projects/conda/en/latest/user-guide/install/index.html)

Hit yes and make sure to run the `init` script if prompted.

### Create an Environment Called Spatial
First thing we need to do is create a conda environment. Think of this as a sandbox for installing a new version of python with only a few chosen modules.

Open `terminal` on a mac/linux or open `anaconda command prompt` or `command prompt` in windows. Then run the following to create an environment called `spatial`:

``` bash
conda create -n spatial python=3.9
```
Now that we have created the environment, let's jump in it! After which you should see `(spatial)` on the left hand side of your terminal.

``` bash
conda activate spatial
```
To avoid conflicting dependencies let's add the channel called `conda-forge` (a user maintained list of python modules) and set it to only search there, by setting priority to `strict`.

``` bash
conda config --add channels conda-forge
conda config --set channel_priority strict
```

Now let's install most of the modules we will need in this book:

``` bash
conda install geowombat geopandas rasterio matplotlib pandas
```
Now install those that aren't available through conda's channels:

``` bash
pip install sklearn-xarray pip-tools rtree ipykernel osmnx PyKrige census us
```
That's it! To learn more about managing environments in conda please refer to the [docs here](https://docs.conda.io/projects/conda/en/latest/user-guide/tasks/manage-environments.html).

```{Important}
Note that every time you want to use your `spatial` environment. You will need to select it in your IDE or open a terminal window and type `conda activate spatial`, you can then launch your IDE via the command line.
```




## Docker for Spatial Python - GDAL Included
Docker allows us to essentially package and share operating systems with specific modifications. Importantly for us this includes libraries and dependencies that are difficult to install otherwise (I'm looking at you GDAL). Before we start you should familiarize yourself with the basic concepts behind Docker, please read the following: [a simple intro to Docker concepts](https://docs.microsoft.com/en-us/dotnet/architecture/microservices/container-docker-introduction/docker-defined)

Expand Down
6 changes: 3 additions & 3 deletions pygis/_build/html/_sources/docs/b_getting_started.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"cells": [
{
"cell_type": "markdown",
"id": "596074aa",
"id": "91c0c3dc",
"metadata": {},
"source": [
"(b_getting_started)=\n",
Expand Down Expand Up @@ -239,7 +239,7 @@
{
"cell_type": "code",
"execution_count": 1,
"id": "e32ce415",
"id": "33838394",
"metadata": {},
"outputs": [
{
Expand Down Expand Up @@ -280,7 +280,7 @@
},
{
"cell_type": "markdown",
"id": "eeb3d6ea",
"id": "4fe871f3",
"metadata": {},
"source": [
"Don\\'t worry about the details for now --- let\\'s just run it and see\n",
Expand Down
2 changes: 1 addition & 1 deletion pygis/_build/html/_sources/docs/b_intro_py.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"cells": [
{
"cell_type": "markdown",
"id": "83938a51",
"id": "af6d1ef1",
"metadata": {},
"source": [
"(b_intro_py)=\n",
Expand Down
40 changes: 20 additions & 20 deletions pygis/_build/html/_sources/docs/b_learn_more.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"cells": [
{
"cell_type": "markdown",
"id": "25fba9e5",
"id": "2f01c9c1",
"metadata": {},
"source": [
"# Learn More\n",
Expand All @@ -25,7 +25,7 @@
{
"cell_type": "code",
"execution_count": 1,
"id": "90881188",
"id": "2fe15f24",
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -38,7 +38,7 @@
},
{
"cell_type": "markdown",
"id": "5003e4bf",
"id": "f68ec785",
"metadata": {},
"source": [
"Now let\\'s take the inner product"
Expand All @@ -47,7 +47,7 @@
{
"cell_type": "code",
"execution_count": 2,
"id": "7baf1a9f",
"id": "0e293976",
"metadata": {},
"outputs": [
{
Expand All @@ -67,7 +67,7 @@
},
{
"cell_type": "markdown",
"id": "00aecff7",
"id": "67e27581",
"metadata": {},
"source": [
"The number you see here might vary slightly due to floating point arithmetic\n",
Expand All @@ -94,7 +94,7 @@
{
"cell_type": "code",
"execution_count": 3,
"id": "bcbed9d5",
"id": "7b2395a0",
"metadata": {},
"outputs": [
{
Expand All @@ -119,7 +119,7 @@
},
{
"cell_type": "markdown",
"id": "04731022",
"id": "f3f0d0d2",
"metadata": {},
"source": [
"SciPy includes many of the standard routines used in\n",
Expand Down Expand Up @@ -181,7 +181,7 @@
{
"cell_type": "code",
"execution_count": 4,
"id": "1e0f6075",
"id": "ed9f2a2a",
"metadata": {},
"outputs": [
{
Expand All @@ -205,7 +205,7 @@
},
{
"cell_type": "markdown",
"id": "7c566941",
"id": "e9697d37",
"metadata": {},
"source": [
"We can manipulate expressions"
Expand All @@ -214,7 +214,7 @@
{
"cell_type": "code",
"execution_count": null,
"id": "e44e4dc5",
"id": "47333b4b",
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -224,7 +224,7 @@
},
{
"cell_type": "markdown",
"id": "8e84e0e9",
"id": "f933dfda",
"metadata": {},
"source": [
"solve polynomials"
Expand All @@ -233,7 +233,7 @@
{
"cell_type": "code",
"execution_count": null,
"id": "90affe72",
"id": "0153dc89",
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -244,7 +244,7 @@
},
{
"cell_type": "markdown",
"id": "6e250698",
"id": "26302dea",
"metadata": {},
"source": [
"and calculate limits, derivatives and integrals"
Expand All @@ -253,7 +253,7 @@
{
"cell_type": "code",
"execution_count": null,
"id": "59befa94",
"id": "dc63c7c6",
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -265,7 +265,7 @@
{
"cell_type": "code",
"execution_count": null,
"id": "281a45fb",
"id": "b82c1c6e",
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -275,7 +275,7 @@
{
"cell_type": "code",
"execution_count": null,
"id": "ce010304",
"id": "9c835535",
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -284,7 +284,7 @@
},
{
"cell_type": "markdown",
"id": "ff1ef0c3",
"id": "d765e0c7",
"metadata": {},
"source": [
"The beauty of importing this functionality into Python is that we are\n",
Expand All @@ -307,7 +307,7 @@
{
"cell_type": "code",
"execution_count": null,
"id": "40ce8e7b",
"id": "001e3aa1",
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -324,7 +324,7 @@
{
"cell_type": "code",
"execution_count": null,
"id": "e27e756f",
"id": "7a4767f4",
"metadata": {},
"outputs": [],
"source": [
Expand All @@ -333,7 +333,7 @@
},
{
"cell_type": "markdown",
"id": "1504e295",
"id": "d1688aa4",
"metadata": {},
"source": [
"## Further Reading\n",
Expand Down
84 changes: 42 additions & 42 deletions pygis/_build/html/_sources/docs/b_python_by_example.ipynb

Large diffs are not rendered by default.

Loading

0 comments on commit 4c4bc9e

Please sign in to comment.