Skip to content

Instantly share code, notes, and snippets.

View aakash30jan's full-sized avatar

Aakash Patil aakash30jan

  • Stanfod | MINES ParisTech
  • Palo Alto, CA
  • 00:59 (UTC -07:00)
View GitHub Profile
# hDSC_MS.py
#http://www.seas.ucla.edu/fluidflow/lib/hDSC_MS.py
# 2018 K. Fukami
## Hybrid Down-sampled skip-connection (DSC) multi-scale (MS) model.
## Author: Kai Fukami (Keio University, Florida State University, University of California, Los Angeles)
## Kai Fukami provides no guarantees for this code. Use as-is and for academic research use only; no commercial use allowed without permission. For citations, please use the reference below:
# Ref: K. Fukami, K. Fukagata, & K. Taira,
# "Super-resolution reconstruction of turbulent flows with machine learning,"
@aakash30jan
aakash30jan / SampleCode.py
Last active May 29, 2020 22:43
python3 venv packages for SampleCode.py
"""
numpy 1.17.3
tensorflow 2.0.0
netCDF4 1.5.3
Get these: "pip install -r https://gist.githubusercontent.com/aakash30jan/9ae0cf3dde8a63d28df5275873cb0f10/raw/9e8d7e1f84fc2f67fe842d75e8623756319786bb/requirements.txt"
Get full environment: "pip install -r https://gist.githubusercontent.com/aakash30jan/9ae0cf3dde8a63d28df5275873cb0f10/raw/9e8d7e1f84fc2f67fe842d75e8623756319786bb/frozen-requirements.txt"
"""
##The sequence of import which doesn't work
import numpy as np
import tensorflow as tf ### <<< if imported here, saving .nc doesn't work
@aakash30jan
aakash30jan / sampleCodeFunction.py
Last active May 29, 2020 22:45
Possible TF2.0 or NetCDF4 Issue
"""
numpy 1.17.3
tensorflow 2.0.0
netCDF4 1.5.3
Get these: "pip install -r https://gist.githubusercontent.com/aakash30jan/9ae0cf3dde8a63d28df5275873cb0f10/raw/9e8d7e1f84fc2f67fe842d75e8623756319786bb/requirements.txt"
Get full environment: "pip install -r https://gist.githubusercontent.com/aakash30jan/9ae0cf3dde8a63d28df5275873cb0f10/raw/9e8d7e1f84fc2f67fe842d75e8623756319786bb/frozen-requirements.txt"
"""
#It's weird that the sequence of importing libraries is affecting i/o of nc file.
import numpy as np
@aakash30jan
aakash30jan / scrapper.py
Last active May 4, 2020 15:36
Build your book library
#Tweaked chris-hamberg/springer_books original script.
from subprocess import call
try:
import pandas as pd
import lxml.html
except:
print("Need to get some stuff . . .")
call("pip install -r https://raw.githubusercontent.com/aakash30jan/springer_books/master/requirements.txt", shell=True)
import pandas as pd
import lxml.html