Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file has been truncated, but you can view the full file.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"config": {"background": "#F1F4F4", "padding": 0, "view": {"continuousWidth": 600, "continuousHeight": 300, "strokeOpacity": 0}, "autosize": {"contains": "padding", "type": "fit-x"}, "title": {"font": "IBM Plex Sans", "fontsize": 16, "fontSize": 16}, "text": {"font": "IBM Plex Sans", "fontsize": 14}, "header": {"font": "IBM Plex Sans", "titleFont": "IBM Plex Sans", "titleFontSize": 20, "labelFont": "IBM Plex Sans", "labelFontSize": 18}, "axis": {"labelFont": "IBM Plex Sans", "titleFont": "IBM Plex Sans", "labelFontSize": 14, "titleFontSize": 16}, "mark": {"font": "IBM Plex Sans", "fontSize": 14}, "legend": {"labelFont": "IBM Plex Sans", "titleFont": "IBM Plex Sans", "labelFontSize": 14, "titleFontSize": 14}}, "vconcat": [{"layer": [{"data": {"url": "https://vega.github.io/vega-datasets/data/world-110m.json", "format": {"feature": "countries", "type": "topojson"}}, "mark": {"type": "geoshape", "fill": "lightgray", "stroke": "none"}, "height": 480, "projection": {"type": "naturalEarth1"}, "width": 800}, {"data |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
def outline_to_mask(line, x, y): | |
"""Create mask from outline contour | |
Parameters | |
---------- | |
line: array-like (N, 2) | |
x, y: 1-D grid coordinates (input for meshgrid) |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
gistup |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# requires: https://github.com/jameskermode/f90wrap | |
# basically this is a wrapper around f2py...: | |
# - the fortran code is rewritten by f90wrap into a f90wrap_module.f90 | |
# so that there is no type defined (which are not supported by f2py break) | |
# - the same step also produces a python module that wraps the newly written f90wrap_module.f90 into fortran | |
# - compile the fortran wrapper with a few nice additions such as | |
# handling optional arguments, and defining the f90wrap_abort() function to raise an error in python | |
# without crashing the program... | |
# name of python module to be created |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
NewerOlder