sudo apt install zsh-autosuggestions zsh-syntax-highlighting zsh
import datacube | |
import numpy as np | |
import xarray as xr | |
from odc.algo import xr_reproject | |
from pyproj import Proj, transform | |
from datacube.utils.geometry import assign_crs | |
from datacube.testutils.io import rio_slurp_xarray | |
from deafrica_tools.bandindices import calculate_indices | |
def common_ops(ds, era): |
(ns user) | |
; Hey, I've been playing a bit with graphing out the structure of a module for Lightpad. | |
; It worked well, I've found the target function that I'll need change to add a new feature. | |
; Tweet with a screenshot https://twitter.com/spacegangster/status/1324760381735272450 | |
; lein coordinate | |
; [com.gfredericks/clj-usage-graph "0.3.0"] | |
; https://github.com/gfredericks/clj-usage-graph | |
macOS has ncurses version 5.7 which does not ship the terminfo description for tmux. There're two ways that can help you to solve this problem.
Instead of tmux-256color
, use screen-256color
which comes with system. Place this command into ~/.tmux.conf
or ~/.config/tmux/tmux.conf
(for version 3.1 and later):
from __future__ import division | |
import scipy.optimize | |
import numpy as np | |
def bbox_iou(boxA, boxB): | |
# https://www.pyimagesearch.com/2016/11/07/intersection-over-union-iou-for-object-detection/ | |
# ^^ corrected. | |
# Determine the (x, y)-coordinates of the intersection rectangle | |
xA = max(boxA[0], boxB[0]) |
(def t (java.io.File/createTempFile "filename" ".txt")) | |
(println (.getPath t)) | |
(defn row [n] | |
[(+ n 500000) (rand-int 10000) (rand-int 10000) (rand-int 10000) (rand-int 10000) 5550555 (rand) "hello world"]) | |
(with-open [w (io/writer t)] | |
(csv/write-csv w (map row (range 1000000)))) | |
(j/with-db-transaction [tx db-spec] |
""" | |
A bare bones examples of optimizing a black-box function (f) using | |
Natural Evolution Strategies (NES), where the parameter distribution is a | |
gaussian of fixed standard deviation. | |
""" | |
import numpy as np | |
np.random.seed(0) | |
# the function we want to optimize |