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

Dianne sept28 #114

Merged
merged 6 commits into from Oct 5, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
20 changes: 6 additions & 14 deletions Notebooks/2_1_1_a_Synthetic_Mag_Data_Profile.ipynb
Expand Up @@ -29,25 +29,17 @@
"source": [
"## Load all libraries and setup the synthetic problem\n",
"from GeoToolkit.Mag import Simulator, DataIO\n",
"dataGrid = DataIO.loadGeoTiffFile(\"./assets/Synthetic/DataGrid.tiff\", plotIt=False)"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"dataGrid = DataIO.loadGeoTiffFile(\"./assets/Synthetic/DataGrid.tiff\", plotIt=False)\n",
"param = Simulator.ViewMagSurveyWidget(dataGrid, shapeFile='./assets/Synthetic/Synthetic_Zcontours.shp')\n",
"display(param)"
]
},
{
"cell_type": "code",
"execution_count": null,
"cell_type": "markdown",
"metadata": {},
"outputs": [],
"source": []
"source": [
" "
]
}
],
"metadata": {
Expand All @@ -66,7 +58,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.6"
"version": "3.6.4"
}
},
"nbformat": 4,
Expand Down
2 changes: 1 addition & 1 deletion Notebooks/2_1_1_b_Synthetic_Mag_Data_Mag_Field.ipynb
Expand Up @@ -73,7 +73,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.6"
"version": "3.6.4"
}
},
"nbformat": 4,
Expand Down
2 changes: 1 addition & 1 deletion Notebooks/2_1_2_Synthetic_Data_Gridding.ipynb
Expand Up @@ -67,7 +67,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.6"
"version": "3.6.4"
}
},
"nbformat": 4,
Expand Down
2 changes: 1 addition & 1 deletion Notebooks/2_1_3_Synthetic_Mag_Data_Visualization.ipynb
Expand Up @@ -71,7 +71,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.6"
"version": "3.6.4"
}
},
"nbformat": 4,
Expand Down
9 changes: 8 additions & 1 deletion Notebooks/2_1_4_Synthetic_Mag_Data_Filters.ipynb
Expand Up @@ -44,6 +44,13 @@
" shapeFile='./assets/Synthetic/Synthetic_Zcontours.shp')\n",
"display(selection)"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
Expand All @@ -62,7 +69,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.6"
"version": "3.6.4"
}
},
"nbformat": 4,
Expand Down
9 changes: 8 additions & 1 deletion Notebooks/2_1_5_Synthetic_Mag_Data_DepthSource.ipynb
Expand Up @@ -48,6 +48,13 @@
"view = Simulator.gridTilt2Depth(dataGrid, HSTransp=0, ColorMap='Greys_r', shapeFile='./assets/Synthetic/Synthetic_Zcontours.shp', omit=['GridFileName', \"EPSGcode\", 'SaveGrid', 'ShapeFileName', 'SaveShape'])\n",
"display(view)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
" "
]
}
],
"metadata": {
Expand All @@ -66,7 +73,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.6"
"version": "3.6.4"
}
},
"nbformat": 4,
Expand Down
11 changes: 9 additions & 2 deletions Notebooks/2_2_1_Search_Mag_Data_Visualization.ipynb
Expand Up @@ -78,7 +78,7 @@
"\n",
"Try different combinations of sun-shading and color settings to see how the image and visibilty of different features is affected.\n",
"\n",
"[If you have installed the Toolkit locally](http://toolkit.geosci.xyz/content/installation.html), this grid can be exported as a located image (geoTiff) and loaded into any software that accepts these types of files, including Google Earth and ArcMap. Try it! Give your file a unique name in the **'GeoTiff name'** box, and click on the **'Export geoTiff'** button. The coordinate system the Search Phase II data files are exported in is NAD 83 UTM Zone 9, EPSG code 3156, unless a new EPSG code is specified in the EPSG code box. **To use the image in GoogleEarth, export with EPSG=4326**\n"
"[If you have installed the Toolkit locally](http://toolkit.geosci.xyz/content/installation.html), this grid can be exported as a located image (geoTiff) and loaded into any software that accepts these types of files, including Google Earth and ArcMap. Try it! Give your file a unique name in the **'GeoTiff name'** box, and click on the **'Export geoTiff'** button. The coordinate system the Search Phase II data files are exported in is NAD 83 UTM Zone 9, EPSG code 26909, unless a new EPSG code is specified in the EPSG code box. **To use the image in GoogleEarth, export with EPSG=4326**\n"
]
},
{
Expand All @@ -90,6 +90,13 @@
"view = Simulator.dataHillsideWidget(selection.result)\n",
"display(view)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
" "
]
}
],
"metadata": {
Expand All @@ -108,7 +115,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.6"
"version": "3.6.4"
}
},
"nbformat": 4,
Expand Down
13 changes: 11 additions & 2 deletions Notebooks/2_2_2_Search_Mag_Data_Filters.ipynb
Expand Up @@ -59,12 +59,21 @@
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"metadata": {
"scrolled": false
},
"outputs": [],
"source": [
"dataGrid = Simulator.gridFiltersWidget(selection.result, saveAs='SearchFilter')\n",
"display(dataGrid)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
" "
]
}
],
"metadata": {
Expand All @@ -83,7 +92,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.6"
"version": "3.6.4"
}
},
"nbformat": 4,
Expand Down
9 changes: 8 additions & 1 deletion Notebooks/2_2_3_Search_MAg_Data_DepthSource.ipynb
Expand Up @@ -87,6 +87,13 @@
"view = Simulator.gridTilt2Depth(dataGrid.result, ColorMap='Greys_r')\n",
"display(view)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
" "
]
}
],
"metadata": {
Expand All @@ -105,7 +112,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.6"
"version": "3.6.4"
}
},
"nbformat": 4,
Expand Down
51 changes: 40 additions & 11 deletions Notebooks/3_1_UserData.ipynb
Expand Up @@ -4,7 +4,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"# 2.1.2. User Data - Download, grid, explore\n",
"# 3.1. User Data - Download, grid, explore\n",
"\n"
]
},
Expand Down Expand Up @@ -56,7 +56,7 @@
"\n",
"You are restricted here to working with **CSV**, **GeoTiff**, or **Geosoft .grd** files. Ensure that the link you provide to the data directs you to one of these file types. \n",
"\n",
"**Cloud Option**\n",
"**Cloud option**\n",
"------------------\n",
"\n",
"Specify the url of the file to download. For personal repository (Dropbox, GoogleDrive), first generate a sharable link:\n",
Expand All @@ -72,7 +72,7 @@
"Copy the link or the url into the **'path'** box.\n",
"\n",
"\n",
"**Local Drive Option**\n",
"**Local drive option**\n",
"-------------------------\n",
"\n",
"Copy the link to the location into the **'Path'** box. E.g.:\n",
Expand All @@ -93,7 +93,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"An example dataset has been provided for you to try out. Follow the above process using the pre-filled Path below. "
"Run the cell below, an example dataset has been provided for you to try out. Follow the above process using the pre-filled Path below. "
]
},
{
Expand All @@ -112,19 +112,26 @@
"source": [
"# Assign coordinate system and Earth's field parameters\n",
"\n",
"Run the cell below to see the data. If you have submitted CSV data you will be prompted to grid it.\n",
"\n",
"***Warning*** For CSV file format: MinimumCurvature interpolation is computationally expensive. For CSV > 10,000 data points, consider downsampling.\n",
"\n",
"You will need to assign the correct coordinate system for your dataset (the coordinate system your data was collected in), using an EPSG code. The EPSG code will be automatically loaded below if the file is a GeoTiff or a .grd file. EPSG codes can easily be found with a google search (e.g. EPSG UTM Zone 09 N => 26909).\n",
"\n",
"In order to reduce the data to pole (which you need to do for certain applications like tilt-depth estimation), you must include the inclination and declination. This information may be available in associated data collection and processing reports, and is specific to the date and location of the magnetic survey. If it is not available, you can use the Fetch Inc/Dec button to find an approximate inclination and declination for that geographic region over a range of time. The user can choose the inclination and declination for a specific year or pick average values from those recorded between 2000 and 2018. ***Important***: the EPSG code needs to be set correctly to ensure the appropriate inclination and declination data are fetched. \n",
"\n",
"***Warning***\n",
"***Warning*** If you are testing out the example EMAG2 dataset, reducing to pole will require too much time, as the dataset is very large. It is advised to skip the RTP step for this example dataset. \n",
"\n",
"For CSV file format: MinimumCurvature interpolation is computationally expensive. For CSV > 10,000 data points, consider downsampling"
"\n",
"![set_inc_dec](./images/incl_decl_40per_ppt.png)\n"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"metadata": {
"scrolled": false
},
"outputs": [],
"source": [
"if download.result is not None:\n",
Expand All @@ -140,7 +147,9 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"# Specify the grid extend"
"# Specify the grid extent\n",
"\n",
"Run the cell below. Here, you can choose subset of data by moving and resizing the data window (black square in the left image). The selected data are shown in the map on the right. If you are using the global EMAG2 example dataset, you can try windowing to -124 East (Longitude), and 49 North (Latitude) with Vancouver at the center. [If you have installed the Toolkit locally](http://toolkit.geosci.xyz/content/installation.html), you can export the data as a GeoTiff, by assigning a unique file name and specifying the file location (the default location is the the Output folder of the GeoToolkit). "
]
},
{
Expand All @@ -154,10 +163,19 @@
" display(selection)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Run the cell below. You can apply some basic visual enhancements here, and export the map. Or you can continue to the following cells to try 2D filters and tilt-depth estimation. If you change the data window size or location, you will have to re-run the subsequent cells. "
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"metadata": {
"scrolled": false
},
"outputs": [],
"source": [
"if download.result is not None:\n",
Expand All @@ -169,7 +187,9 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"# View data and filters"
"# View data and filters\n",
"\n",
"Run the cell below to apply 2D data filters to your data. You can refer back to sections [2.1.4 (Synthetic case study)](http://toolkit.geosci.xyz/content/Demos/SyntheticFilters.html#synthetic-2d-magnetic-data-filters) and [2.2.2 (Geoscience BC Search II case study)](http://toolkit.geosci.xyz/content/Demos/SearchFilters.html#search-case-study-2d-magnetic-data-filters) to review applications of 2D filters. [If you have installed the Toolkit locally](http://toolkit.geosci.xyz/content/installation.html), you can export the data as a GeoTiff, by assigning a unique file name and specifying the file location (the default location is the the Output folder of the GeoToolkit). "
]
},
{
Expand All @@ -183,6 +203,15 @@
" display(view)"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# Tilt-depth depth to source estimation\n",
"\n",
"Run the cell below to try source edge and depth estimation using the tilt-depth method. You can refer back to sections [2.1.5 (Synthetic case study)](http://toolkit.geosci.xyz/content/Demos/SyntheticTiltDepth.html#synthetic-edge-detection-and-depth-to-source) and [2.2.3 (Geoscience BC Search II case study)](http://toolkit.geosci.xyz/content/Demos/SearchTiltDepth.html#search-case-study-edge-detection-and-depth-to-source) to review applications of 2D filters. [If you have installed the Toolkit locally](http://toolkit.geosci.xyz/content/installation.html), the grid can be exported as a located image (geoTiff). Give your file a unique name in the 'GeoTiff name' box, choose a file location (the default location is the the Output folder of the GeoToolkit), and click on the 'Export GeoTiff' button. The tilt angle contours defining magnetic source edges and carrying depth data can be exported as a Shapefile using the 'Export Shapefile' button. "
]
},
{
"cell_type": "code",
"execution_count": null,
Expand Down Expand Up @@ -218,7 +247,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.6"
"version": "3.6.4"
}
},
"nbformat": 4,
Expand Down
Binary file added Notebooks/images/incl_decl_40per_ppt.png
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 Notebooks/index.ipynb
Expand Up @@ -69,7 +69,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.6.6"
"version": "3.6.4"
}
},
"nbformat": 4,
Expand Down
12 changes: 6 additions & 6 deletions docs/content/Demos/SearchFilters.rst
Expand Up @@ -31,7 +31,7 @@ Below is a snapshot of the gridded total magnetic intensity data from a subregio
Upward continuation
-------------------

Upward continuation simulates the magnetic response at increased heights above the Earth’s surface and emphasizes longer-wavelength, deeper features, making it effective for interpretation of deep geology.
Upward continuation **simulates the magnetic response at increased heights above the Earth’s surface** and emphasizes longer-wavelength, deeper features, making it effective for interpretation of deep geology.

An upward continuation filter is applied to the Search Phase II data below. In the interactive notebook, try an upward continuation distance of 100 m, then 200 m. Detail in the magnetic data is lost, however certain magnetic features persist, giving interpreters a sense of the deep geology underlying the chosen study area.

Expand All @@ -43,7 +43,7 @@ An upward continuation filter is applied to the Search Phase II data below. In t
X and Y derivatives of the magnetic response
--------------------------------------------

:ref:`X and Y derivatives<synthfilters_XY_deriv>` emphasize magnetic gradients in the X and Y directions, respectively. The steepest gradients occur where there are contrasts in magnetic susceptibility between adjacent rock rocks or due to cross-cutting structures. Anomalies in X and Y derivative data thus peak over geologic contacts, faults, or fractures.
:ref:`X and Y derivatives<synthfilters_XY_deriv>` emphasize magnetic gradients in the X and Y directions, respectively. The steepest gradients occur where there are contrasts in magnetic susceptibility between adjacent rocks or due to cross-cutting structures. **Anomalies in X and Y derivative data thus peak over geologic contacts, faults, or fractures**

Grids showing the X and Y derivatives of the windowed Search Phase II magnetic data are shown below. North-south trending features are highlighted in the X derivative data, and east-west trending features highlighted in the Y derivative data.

Expand All @@ -56,7 +56,7 @@ Grids showing the X and Y derivatives of the windowed Search Phase II magnetic d
Vertical derivative
-------------------

The :ref:`vertical derivative<synthfilters_vert_deriv>` represents the difference between the magnetic response measured at two different heights above the Earth. First vertical derivative anomalies will highlight edges of magnetic sources, and appear over the top of the source if the contact or feature is vertical.
The :ref:`vertical derivative<synthfilters_vert_deriv>` represents the difference between the magnetic response measured at two different heights above the Earth. **First vertical derivative anomalies will highlight edges of magnetic sources, and appear over the top of the source if the contact or feature is vertical**.

The Search II data are filtered here to yield the first vertical derivative.

Expand All @@ -68,7 +68,7 @@ The Search II data are filtered here to yield the first vertical derivative.
Total horizontal derivative
---------------------------

The :ref:`total horizontal derivative<synthfilters_tot_horiz_deriv>` is calculated by combining the X and Y derivatives. The highest total horizontal derivative values occur at the edges or boundaries of magnetic sources.
The :ref:`total horizontal derivative<synthfilters_tot_horiz_deriv>` is calculated by combining the X and Y derivatives. **The highest total horizontal derivative values occur at the edges or boundaries of magnetic sources**.

The total horizonal derivative of the Search Phase II data is plotted below. The map has a worm-like texture as geologic 'edges' are being emphasized.

Expand All @@ -79,7 +79,7 @@ The total horizonal derivative of the Search Phase II data is plotted below. The
Tilt angle
----------

The :ref:`tilt angle<synthfilters_tilt_angle>` tilt angle normalizes the vertical derivative by the horizontal derivatives. The tilt angle will yield a result that gives an equal emphasis to both large and smaller anomalies. The tilt angle is positive over the magnetic source, and negative outside the source, with edges of sources delimited by the 0 degree contour.
The :ref:`tilt angle<synthfilters_tilt_angle>` tilt angle normalizes the vertical derivative by the horizontal derivatives. **The tilt angle will yield a result that gives an equal emphasis to both large and smaller anomalies**. The tilt angle is positive over the magnetic source, and negative outside the source, with edges of sources delimited by the 0 degree contour.

Applying a tilt angle filter to the Search II data, we get a map with lots of anomalies. You can see more detail now in magnetically 'quiet' regions than previously seen in the X and Y derivative maps. This is very helpful for distinguishing features in weakly magnetic areas, but makes it more difficult to identify the discrete stronger magnetic anomalies in the area seen in some of the other derivative maps.

Expand All @@ -92,7 +92,7 @@ Applying a tilt angle filter to the Search II data, we get a map with lots of an
Analytic signal
---------------

The :ref:`analytic signal<synthfilters_an_sig>` or total gradient is calculated from the vertical and horizontal derivatives, accounting for magnetic contrasts in all three directions. The analytic signal peaks immediately above narrow bodies and along the edges of larger geologic features that are in magnetic contrast to their surroundings.
The :ref:`analytic signal<synthfilters_an_sig>` or total gradient is calculated from the vertical and horizontal derivatives, accounting for magnetic contrasts in all three directions. **The analytic signal peaks immediately above narrow bodies and along the edges of larger geologic features that are in magnetic contrast to their surroundings**.

The analytic signal of the Search II data does appear to peak over the tops of, and define the extents of smaller anomalous bodies. The result shows similarities to both the first vertical derivative and the total horizontal gradient which makes sense due to the incorporation of the three gradients (X, Y, Z) in the calculation.

Expand Down