Skip to content

Commit

Permalink
updating docs build with aylas changes
Browse files Browse the repository at this point in the history
  • Loading branch information
lachlangrose committed Feb 1, 2024
1 parent 975184b commit 1d3d76a
Show file tree
Hide file tree
Showing 42 changed files with 3,551 additions and 95 deletions.
2 changes: 1 addition & 1 deletion .buildinfo
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Sphinx build info version 1
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
config: 41df95f0b456467426b3a4993c4edb55
config: cfcb5948b1fcdbad51b18af9e03a2903
tags: 645f666f9bcd5a90fca523b33c5a78b7
6 changes: 3 additions & 3 deletions API.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<title>API &#8212; map2loop 3.0.4 documentation</title>
<title>API &#8212; map2loop 3.0.6 documentation</title>



Expand Down Expand Up @@ -39,7 +39,7 @@
<link rel="preload" as="script" href="_static/scripts/pydata-sphinx-theme.js?digest=bd9e20870c6007c4c509" />
<script src="_static/vendor/fontawesome/6.5.1/js/all.min.js?digest=bd9e20870c6007c4c509"></script>

<script src="_static/documentation_options.js?v=50b65552"></script>
<script src="_static/documentation_options.js?v=c3365b21"></script>
<script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script>DOCUMENTATION_OPTIONS.pagename = 'API';</script>
Expand Down Expand Up @@ -120,7 +120,7 @@



<p class="title logo__title">map2loop 3.0.4 documentation</p>
<p class="title logo__title">map2loop 3.0.6 documentation</p>

</a></div>

Expand Down
6 changes: 3 additions & 3 deletions _auto_examples/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<title>Examples &#8212; map2loop 3.0.4 documentation</title>
<title>Examples &#8212; map2loop 3.0.6 documentation</title>



Expand Down Expand Up @@ -39,7 +39,7 @@
<link rel="preload" as="script" href="../_static/scripts/pydata-sphinx-theme.js?digest=bd9e20870c6007c4c509" />
<script src="../_static/vendor/fontawesome/6.5.1/js/all.min.js?digest=bd9e20870c6007c4c509"></script>

<script src="../_static/documentation_options.js?v=50b65552"></script>
<script src="../_static/documentation_options.js?v=c3365b21"></script>
<script src="../_static/doctools.js?v=888ff710"></script>
<script src="../_static/sphinx_highlight.js?v=dc90522c"></script>
<script>DOCUMENTATION_OPTIONS.pagename = '_auto_examples/index';</script>
Expand Down Expand Up @@ -122,7 +122,7 @@



<p class="title logo__title">map2loop 3.0.4 documentation</p>
<p class="title logo__title">map2loop 3.0.6 documentation</p>

</a></div>

Expand Down
6 changes: 3 additions & 3 deletions _auto_examples/plot_hamersley.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<title>Hamersley, Western Australia &#8212; map2loop 3.0.4 documentation</title>
<title>Hamersley, Western Australia &#8212; map2loop 3.0.6 documentation</title>



Expand Down Expand Up @@ -39,7 +39,7 @@
<link rel="preload" as="script" href="../_static/scripts/pydata-sphinx-theme.js?digest=bd9e20870c6007c4c509" />
<script src="../_static/vendor/fontawesome/6.5.1/js/all.min.js?digest=bd9e20870c6007c4c509"></script>

<script src="../_static/documentation_options.js?v=50b65552"></script>
<script src="../_static/documentation_options.js?v=c3365b21"></script>
<script src="../_static/doctools.js?v=888ff710"></script>
<script src="../_static/sphinx_highlight.js?v=dc90522c"></script>
<script>DOCUMENTATION_OPTIONS.pagename = '_auto_examples/plot_hamersley';</script>
Expand Down Expand Up @@ -122,7 +122,7 @@



<p class="title logo__title">map2loop 3.0.4 documentation</p>
<p class="title logo__title">map2loop 3.0.6 documentation</p>

</a></div>

Expand Down
6 changes: 3 additions & 3 deletions _auto_examples/sg_execution_times.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<title>Computation times &#8212; map2loop 3.0.4 documentation</title>
<title>Computation times &#8212; map2loop 3.0.6 documentation</title>



Expand Down Expand Up @@ -39,7 +39,7 @@
<link rel="preload" as="script" href="../_static/scripts/pydata-sphinx-theme.js?digest=bd9e20870c6007c4c509" />
<script src="../_static/vendor/fontawesome/6.5.1/js/all.min.js?digest=bd9e20870c6007c4c509"></script>

<script src="../_static/documentation_options.js?v=50b65552"></script>
<script src="../_static/documentation_options.js?v=c3365b21"></script>
<script src="../_static/doctools.js?v=888ff710"></script>
<script src="../_static/sphinx_highlight.js?v=dc90522c"></script>
<script>DOCUMENTATION_OPTIONS.pagename = '_auto_examples/sg_execution_times';</script>
Expand Down Expand Up @@ -120,7 +120,7 @@



<p class="title logo__title">map2loop 3.0.4 documentation</p>
<p class="title logo__title">map2loop 3.0.6 documentation</p>

</a></div>

Expand Down
6 changes: 3 additions & 3 deletions _autosummary/map2loop.Project.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<title>map2loop.Project &#8212; map2loop 3.0.4 documentation</title>
<title>map2loop.Project &#8212; map2loop 3.0.6 documentation</title>



Expand Down Expand Up @@ -39,7 +39,7 @@
<link rel="preload" as="script" href="../_static/scripts/pydata-sphinx-theme.js?digest=bd9e20870c6007c4c509" />
<script src="../_static/vendor/fontawesome/6.5.1/js/all.min.js?digest=bd9e20870c6007c4c509"></script>

<script src="../_static/documentation_options.js?v=50b65552"></script>
<script src="../_static/documentation_options.js?v=c3365b21"></script>
<script src="../_static/doctools.js?v=888ff710"></script>
<script src="../_static/sphinx_highlight.js?v=dc90522c"></script>
<script>DOCUMENTATION_OPTIONS.pagename = '_autosummary/map2loop.Project';</script>
Expand Down Expand Up @@ -121,7 +121,7 @@



<p class="title logo__title">map2loop 3.0.4 documentation</p>
<p class="title logo__title">map2loop 3.0.6 documentation</p>

</a></div>

Expand Down
6 changes: 3 additions & 3 deletions _autosummary/map2loop.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="generator" content="Docutils 0.18.1: http://docutils.sourceforge.net/" />

<title>map2loop &#8212; map2loop 3.0.4 documentation</title>
<title>map2loop &#8212; map2loop 3.0.6 documentation</title>



Expand Down Expand Up @@ -39,7 +39,7 @@
<link rel="preload" as="script" href="../_static/scripts/pydata-sphinx-theme.js?digest=bd9e20870c6007c4c509" />
<script src="../_static/vendor/fontawesome/6.5.1/js/all.min.js?digest=bd9e20870c6007c4c509"></script>

<script src="../_static/documentation_options.js?v=50b65552"></script>
<script src="../_static/documentation_options.js?v=c3365b21"></script>
<script src="../_static/doctools.js?v=888ff710"></script>
<script src="../_static/sphinx_highlight.js?v=dc90522c"></script>
<script>DOCUMENTATION_OPTIONS.pagename = '_autosummary/map2loop';</script>
Expand Down Expand Up @@ -122,7 +122,7 @@



<p class="title logo__title">map2loop 3.0.4 documentation</p>
<p class="title logo__title">map2loop 3.0.6 documentation</p>

</a></div>

Expand Down
Binary file added _images/csv.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 added _images/fault_attributes_table.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 added _images/litho_attributes_table.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 added _images/ori_attributes_table.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 2 additions & 2 deletions _sources/sg_execution_times.rst.txt
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

Computation times
=================
**00:19.460** total execution time for 1 file **from all galleries**:
**00:00.000** total execution time for 1 file **from all galleries**:

.. container::

Expand All @@ -33,5 +33,5 @@ Computation times
- Time
- Mem (MB)
* - :ref:`sphx_glr__auto_examples_plot_hamersley.py` (``..\..\examples\plot_hamersley.py``)
- 00:19.460
- 00:00.000
- 0.0
48 changes: 48 additions & 0 deletions _sources/user_guide/changing_colours.rst.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
Changing Colours
================
Using a CSV file
----------------
The easiest way to set the colour of different units in your model is to create a csv file that contains the lithological unit names in one column and the hex colour code in another, as shown below:

.. image:: ../images/csv.png
:width: 500

Changing colours via your Jupyter notebook
------------------------------------------
You can also change unit and fault colours manually in your Jupyter notebook. There are examples of the code you can use to achieve this below. Importantly, if you decide to use this method, you’ll need to call this code after the creation of ‘model’ in your Jupyter notebook.
The stratigraphy data is stored in a python dictionary, so to change the colour of specific elements you need to use the associated key. In the below cases you need to navigate through the nested dictionaries to find the colour value. To view the contents of the stratigraphic column dictionary in your own notebook you can just use the command:

.. code-block:: python
model. stratigraphic_column
To view a dictionary nested within the stratigraphic_column dictionary you will need to specify the key, for example:

.. code-block:: python
model.stratigraphic_column['sg']
If you run this command, you’ll get an output showing the sg dictionary (which contains all of the rock units) as well as any dictionaries nested within it.


Unit Colours
.............
Following on from the above explanation, to access the unit colour you will need to navigate from the stratigraphic_column dictionary through the dictionaries nested within it. In the example below you’ll navigate to ‘sg’ then ‘unit_name’ then ‘colour’ where you can finally edit the hex colour value.

Make sure to replace ‘unit_name’ with the name of the unit you want to change and the ‘#f71945’ with the hex colour code you desire. Remember you can check these values by running and inspecting the output of: model. stratigraphic_column

.. code-block:: python
model.stratigraphic_column['sg']['unit_name']['colour'] = '#f71945'
Fault Colours
..............
The code to change the colour of faults is very similar, where ‘fault_name’ is the name of the fault you’re editing.

.. code-block:: python
model.stratigraphic_column['faults']['fault_name’]['colour'] = '#f25d27'
Please see the examples for further clarification.
64 changes: 64 additions & 0 deletions _sources/user_guide/config_file.rst.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
Mapping attributes to variables using an HJSON file
===================================================
Once you’ve completed your map in QGIS, you’ll need to map the attributes (with whatever names you’ve given them) to the variable names used in map2loop. You can map the attributes to the variable names used in version 2 or 3 of map2loop, as specified in the tables in the Setting up your Shapefiles section.
An example hjson file is shown below, using map2loop-2 variable names (also known as Legacy code. If you decide to use map2loop-2 variable names, you will have to set the legacy flag to true in the map2loop calling code later on. If you use map2loop-3 variable names you'll need to set the legacy flag to false.

Feel free to copy the attached template and fill in the required variables with the attribute names specific to your project.

Config File Template
---------------------
The templates below demonstrate how to setup a config file for map2loop.
Explanations of the HJSON file elements:

* The left most 'term' is the map2loop variable name
* The information after the hash on the right is a description of the required field. You can delete this from your own file if you'd like.
* You'll need to change the attribute name in the second quotation to match your shapefile attribute names (e.g. change "INSERT_DIP" to your attribute name). Ensure that the attribute name is between '' or "".
* Any lines with a *opt in the description string, means that they are optional. If you don't want to include them, just leave the attribute field blank (e.g. "g": '', )
For more information on the variables and map2loop requirements please see the documentation.

Legacy Variable Names (map2loop-2) Template
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Note, there is an inbuilt converter within map2loop so you can use either of the config files with the most recent version of map2loop.

.. codeblock:: JSON
{
#ORIENTATION SHAPEFILE ATTRIBUTES
"d": "INSERT_DIP", #attribute containing dip information
"dd": "INSERT_DIP_DIRECTION", #attribute containing dip direction information
"otype": 'dip direction', #Set the measurement convention used (either 'strike' or 'dip direction')
"sf": 'INSERT_STRUCTURE_DESCRIPTION', #*opt attribute containing type of structure (eg. S0, S1)
"bedding": 'INSERT_BEDDING_TEXT', #*opt text defining bedding measurements in the "sf" field (eg "Bedding" or "S0")
"bo": 'INSERT_FOLIATION_DESCRIPTION', #*opt attribute containing type of foliation
"btype": 'OVERTURNED_BEDDING_TEXT', #*opt text defining overturned bedding measurements in the "bo" field (eg. 'overturned')
#LITHOLOGY SHAPEFILE ATTRIBUTES
"c": 'INSERT_UNIT_NAME', #attribute containing stratigraphic unit name (most specific)
"u": 'INSERT_ALT_UNIT_NAME', #attribute containing alternative stratigraphic unit name (eg unit code). Can be the same as 'c'
"g": 'INSERT_GROUP', #*opt attribute containing stratigraphic group
"g2": 'INSERT_SUPERGROUP', #*opt attribute containing stratigraphic supergroup (most coarse classification)
"ds": 'INSERT_DESCRIPTION', #*opt general description field
"r1": 'INSERT_ROCKTYPE', #*opt attribute containing extra lithology information (can indicate intrusions)
"r2": 'INSERT_ROCKTYPE2', #*opt attribute containing secondary rocktype information
"sill": 'INSERT_SILL_TEXT', #*opt text defining a sill in the "ds" field (eg 'sill')
"intrusive": 'INSERT_INTRUSIVE_TEXT', #*opt text defining an intrusion in the "r1" field (eg 'intrusion')
"volcanic": 'INSERT_VOLCANIC_TEXT', #*opt text defining volcanics in the "ds" field (eg 'volcanic')
"min": 'INSERT_MIN_AGE', #*opt attribute containing minimum unit age
"max": 'INSERT_MAX_AGE', #*opt attribute containing maximum unit age
#LINEAR FEATURES SHAPEFILE ATTRIBUTES
"f": 'INSERT_STRUCT_TYPE', #attribute containing linear structure type (e.g. fault)
"fault": 'fault', #text defining faults in the "f" field (eg. 'fault')
"fdip": 'INSERT_FAULT_DIP', #*opt attribute containing numeric fault dip value (defaults to fdipnull)
"fdipnull": '0', #Default fault dip value, if 'fdip' field is empty
"fdipdir": 'INSERT_FAULT_DIP_DIRECTION', #*opt attribute containing the fault dip direction (defaults to -999)
"fdipdir_flag": 'num', #*opt specifies whether fdipdir is "num":numeric or other ("alpha")
"fdipest": 'INSERT_DIP_EST_TEXT', #*opt field for text fault dip estimate value (defaults to none)
"fdipest_vals": 'INSERT_DIP_EST_TERMS', #*opt text used to estimate dip in increasing steepness, in "fdipest" field
"n": 'INSERT_FAULT_NAME', #*opt attribute containing the fault name
#GENERAL IDS
"o": 'INSERT_OBJ_ID', #*opt attribute containing unique object id (used in polygon and lineString shapefiles
"gi": 'INSERT_ORI_ID', #*opt attribute containing unique id of structural points
}

map2loop-3 variable names HJSON File Template
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
This is a template with the most up-to date variable names.
Loading

0 comments on commit 1d3d76a

Please sign in to comment.