Giter VIP home page Giter VIP logo

c4-project.jl's Introduction

C4-Project.jl

C4-Project.jl contains codes for replication of our Ambient-Noise Cross-Correlation method in Julia using High Performance Computing and instructions for accessing our stacked correlation data product. We are also developing a package, SeisCore.jl, with helpful functions for data processing, and plotting. The technical README for the C4 project is also available!

Getting Started

Our data product is stored in an Amazon Web Services S3 cloud storage bucket. Currently access is restricted to team members with public access expected in early 2020. Downloading the product is possible through the AWS user interface or directly using terminal after configuring your amazon credentials using the command aws configure and then downloading our product, either a single file or folder by using appropriate file pathing:

   aws s3 cp s3://seisbasin/source_processed/2017/2017_CI.CHN.h5 ~/Downloads/
   aws s3 cp s3://seisbasin/source_processed/2017/ ~/Downloads/ --recursive

Data Access

We have chosen to store our files in the h5 format given its multi-language readability (see docs). We provide documentation here for both Julia and Python. Below we describe the hierarchical structure of each file and how read our h5 files into julia to access datafields:
Data Pathing Graphic

Contents

Each file contains the following

  1. Source metadata, accessed via the group "meta":
    a. Correlation metadata: corr_type,cc_len, cc_step, whitened, time_norm, notes, maxlag, and starttime.
    b. Source location metadata: lat, lon, el, dep, az, and inc.
  2. Reciever metadata, accessible as a subgroup in the recievere group via "meta":
    a. Correlation metadata: dist, azi, baz.
    b. Receiver location metadata: lat, lon, el, dep, az, and inc.

In Julia

julia> using SeisIO, SeisNoise, HDF5
julia> fid = h5open("2017_CI.CHN.h5","r")
julia> SOURCE = read(fid)

Example

To access desired stacktype, filter desired correlations, and access metadata, your script might leverage the following SeisCore.jl functionality found in our documentation. We include an example of the workflow below:

# select example parameters 
name, stacktype, component, filter = "CHN", "linear", "ZZ", "NO.B4"
frequency_plots = [[0.1,0.2],[0.2,0.5],[0.5,1.]]
lw = 0.5 #Decrease line thickness by half from default for cleaner plots
scale = 0.1 # inversely related to plot amplitude - may need to scale accordingly
rootdir = "/Users/julianschmitt/Desktop/SeisPlots" # chose root directory for plots

# filter and extract correlations and plot
fcorrs = get_corrs(file, stacktype, component, filter)
vert_plot(fcorrs, name, component, filter, stacktype) 

Which produces a plot for each of the 3 selected frequency plots. For example:
Example Plot Graphic
Also checkout our jupyter notebook for more plotting power!

Reproducibility

This section details highlights of our methodology and details how to begin AWS cloud computing in Julia for yourself!

launch EC2 contains instructions and video link for launching an AWS instance and installing Julia for cloud computing. Also checkout our startup youtube video for a guide to Amazon's compute platform. Further docs to come... Happy Computing!

c4-project.jl's People

Contributors

julians42 avatar

Stargazers

Xiao Xiao avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.