Skip to content

Instantly share code, notes, and snippets.

View texasdave2's full-sized avatar

David O'Dell texasdave2

  • Austin
View GitHub Profile
Questions are not from any actual exam!!!
Q: Create a job that calculates pi to 2000 decimal points using the container with the image named perl
and the following commands issued to the container: ["perl", "-Mbignum=bpi", "-wle", "print bpi(2000)"]
Once the job has completed, check the logs to and export the result to pi-result.txt.
Solution:
@texasdave2
texasdave2 / gist:ab3720476c4b68cc6ce081bc137bc1fb
Created September 18, 2023 20:57
simple_nlp_example.ipynb
{
"cells": [
{
"cell_type": "code",
"execution_count": 30,
"metadata": {},
"outputs": [],
"source": [
"## currently gives error:\n",
"\n",
backup etcd and kubeadm
mkdir -p backup
sudo cp -r /etc/kubernetes/pki ./backup
sudo docker run --rm -v $(pwd)/backup:/backup \
https://kubernetes.io/docs/tasks/administer-cluster/kubeadm/kubeadm-upgrade-1-13/
@texasdave2
texasdave2 / image_to_thumbnail.py
Created May 27, 2018 04:36
Thumbnail creator
# -*- coding: utf-8 -*-
"""
Created on Sat May 26 09:10:40 2018
@author: David O'Dell
"""
# Simple script that resizes all images in a directory to 100 x 100 thumbnails"
# script needs to be placed inside target directory
# import libraries
@texasdave2
texasdave2 / volcanoes2010.py
Last active May 11, 2018 03:47
Volcano map test
# -*- coding: utf-8 -*-
"""
Created on Sun May 6 20:29:19 2018
@author: astro 1
"""
#Volcano eruption map from 2010 to present
#data downloaded from
#https://www.ngdc.noaa.gov/nndc/servlet/ShowDatasets?dataset=102557&search_look=50&display_look=50