Skip to content

Instantly share code, notes, and snippets.

View lewiuberg's full-sized avatar
💬
Constructive criticism is welcome 👍

Lewi Uberg lewiuberg

💬
Constructive criticism is welcome 👍
View GitHub Profile
@lewiuberg
lewiuberg / raspberry_pi_time_machine_and_plex.md
Last active April 10, 2024 06:26
Raspberry Pi Time Machine and Plex setup

Source: https://gregology.net/2018/09/raspberry-pi-time-machine/

Raspberry Pi Time Machine

Setup Pi with Raspbian

Install Raspbian Buster Lite on the SD card. Follow the instructions on the Installing images tutorial on the Raspberry Pi site. Then enable SSH. Insert the SD card into the Pi, plug in the USB hard drive, plug in a network cable, and power on the Pi.

Open Preferences and Raspberr pi configuration. Change the hostname to: "AirPort"

Next set a static IP address for your Raspberry Pi. Depending on your setup, you can either set the Pi to have a manual ip address or have your router assign a static IP address.

@lewiuberg
lewiuberg / air-out_01.md
Last active December 28, 2020 13:41
Active Airport out 01
Passengers 2011M01
airport type of traffic Passengers 2010M10 Passengers 2010M11 Passengers 2010M12
@lewiuberg
lewiuberg / missing_location.py
Created December 28, 2020 12:03
Active Airport code 11
miss_col, miss_row, miss_only = missing_location(df)
@lewiuberg
lewiuberg / active_airport.py
Created December 28, 2020 11:21
Active Airport code 12
from dash.dependencies import Input, Output
# from numpy.core.fromnumeric import size
from dash_bootstrap_components._components.Navbar import Navbar
import pandas as pd
import plotly.graph_objects as go
import plotly.express as px
import dash
import dash_table
import dash_bootstrap_components as dbc
import dash_core_components as dcc
@lewiuberg
lewiuberg / air-out_09.md
Created December 28, 2020 11:17
Active Airport out 09
date
airport type of traffic location latitude longitude
@lewiuberg
lewiuberg / long_data.py
Created December 28, 2020 11:16
Active Airport code 11
path = "df_melt.csv"
read = True
if read:
if path_checker(path):
df_melt = pd.read_csv(path)
if "date" in df_melt:
df_melt["date"] = pd.to_datetime(df_melt["date"])
else:
if df is None:
@lewiuberg
lewiuberg / manual_locations.py
Created December 28, 2020 11:11
Active Airport code 10
path = "df_geo_manual.csv"
read = True
if read:
if path_checker(path):
df = pd.read_csv(path)
if "date" in df:
df["date"] = pd.to_datetime(df["date"])
else:
if df is None:
@lewiuberg
lewiuberg / air-out_08.md
Created December 28, 2020 11:10
Active Airport out 08
2011-01-01 00:00:00
airport type of traffic 2010-10-01 00:00:00 2010-11-01 00:00:00 2010-12-01 00:00:00
@lewiuberg
lewiuberg / drop_duplicates.py
Created December 28, 2020 11:05
Active Airport code 09
miss_row_airport = miss_row
miss_row_airport.drop_duplicates("airport")
@lewiuberg
lewiuberg / air-out_07.md
Created December 28, 2020 11:03
Active Airport out 07
2011-01-01 00:00:00
airport type of traffic 2010-10-01 00:00:00 2010-11-01 00:00:00 2010-12-01 00:00:00