Skip to content

Instantly share code, notes, and snippets.

View cvargas-xbrein's full-sized avatar
🎯

Cristián Vargas cvargas-xbrein

🎯
View GitHub Profile
@cvargas-xbrein
cvargas-xbrein / humanity_globe.R
Created September 13, 2023 21:14 — forked from tylermorganwall/humanity_globe.R
3D Humanity Globe
library(rayshader)
library(rayrender)
popdata = raster::raster("gpw_v4_population_density_rev11_2020_15_min.tif")
population_mat = rayshader:::flipud(raster_to_matrix(popdata))
above1 = population_mat > 1
above5 = population_mat > 5
above10 = population_mat > 10
@cvargas-xbrein
cvargas-xbrein / handler.js
Created October 9, 2025 14:05 — forked from adieuadieu/handler.js
AWS OpenSearch Cluster with Serverless Framework
const aws4 = require('aws4')
const host = process.env.OPENSEARCH_ENDPOINT
module.exports.default = async function handler(
event,
context,
) {
const fetch = (await import('node-fetch')).default
const indexName = 'example'