Skip to content

Instantly share code, notes, and snippets.

@alexhiggins732
alexhiggins732 / Directory.Packages.props
Created February 7, 2024 20:07
DotNet8 Directory.Packages.props
<Project>
<PropertyGroup>
<ManagePackageVersionsCentrally>true</ManagePackageVersionsCentrally>
<CentralPackageTransitivePinningEnabled>true</CentralPackageTransitivePinningEnabled>
<AspnetVersion>8.0.0</AspnetVersion>
<AspnetMinorVersion>8.0.1</AspnetMinorVersion>
<MicrosoftExtensionsVersion>8.0.0</MicrosoftExtensionsVersion>
<EfVersion>8.0.0</EfVersion>
<RuntimeVersion>8.0.0</RuntimeVersion>
<AspireVersion>8.0.0-preview.2.23619.3</AspireVersion>
@alexhiggins732
alexhiggins732 / FodyChangeTrackingExample.cs
Created April 19, 2023 19:47
Fody Model Change Tracker
using PropertyChanged;
using System.ComponentModel;
namespace INPCProxy
{
// install package PropertyChanged.Fody
internal class FodyChangeTrackingExample
{
public static void ModifyPerson()
-- candidate
0005
C158
9/19/2022 2:21:13 PM n = ((res+aP+(lp*461))^2)%rsa1024
9/19/2022 2:21:13 PM i = 461
9/19/2022 2:21:13 PM n = 83331543611585435160055622713654775572519289638916208989820130617974087097157784249331428381007523495160855231497315805334517703422861206404787763988682091378693388598673664418559876849772071679260389513209984627691553793137041168314494062390469422111607001163034717188004902712273507947489673541
9/19/2022 2:21:13 PM => PRP139 7776869760488715105553818574431290390372145115150758714456081133327527048615899033108886624480286868212680641187368954026301176875335408993
9/19/2022 2:21:13 PM => C158 10715306566526414733265912459455316155253636549071023754616884478254468288384783796381665410344192223794466084995692126578514864280919529418864669412507265637
9/19/2022 2:21:13 PM ========================================================================================================================
using Bunit;
using Microsoft.Extensions.DependencyInjection;
using Microsoft.VisualStudio.TestTools.UnitTesting;
using MudBlazor.Services;
using System;
using System.Threading.Tasks;
[TestClass()]
public class ViewerBodyTests : BunitTestContext
{
@alexhiggins732
alexhiggins732 / covid-death-vaxx-rates.txt
Created December 9, 2021 01:08
Covid-19 Death And Vaccination Rates - December 8, 2021
Country,Other Deaths Per Million location vaccination_rate
Africa 11.7
Asia 63.62
Cook Islands 71.7
Europe 63.36
European Union 71.18
Falkland Islands 74.6
Greenland 70.82
Guernsey 52.01
High income 74.65
@alexhiggins732
alexhiggins732 / UserLoginLog.cs
Created September 14, 2021 18:42
Parse users logon audits from the Windows Event Log
// <package id="Microsoft.Extensions.Logging" version="5.0.0" targetFramework="net48" />
EventLog eventLog = new EventLog();
eventLog.Log = "Security";
var userNames = new Dictionary<string, int>();
DateTime? logStart = null;
foreach (EventLogEntry entry in eventLog.Entries)
{
if (logStart == null)
logStart = entry.TimeGenerated;
@alexhiggins732
alexhiggins732 / Jupyter-Notebook-Download.Py
Last active April 10, 2021 00:04
Jupyter Notebook Download all files
#From the notebook root directory, compress all files in the notebook to notebook.tar.gz
!tar chvfz "filename.gz" *
# Split the files in to 50 MB chunks to support downloading
!split -b 50m "filename.gz" "filename.gz.part."
# Go to file -> open and download each notebook.tar.gz.part file. Using 7Zip and click on notebook.tar.gz.aa and choose extract all.
@alexhiggins732
alexhiggins732 / KerasA2C.cs
Created February 21, 2021 02:44
Keras Actor Critic in TensorFlow.net
using System;
using System.Collections.Generic;
using NumSharp;
using Tensorflow.Keras.Layers;
using Tensorflow.Keras.Losses;
using Tensorflow.Keras.Optimizers;
using Tensorflow.Keras.Utils;
using static Tensorflow.Binding;
using static Tensorflow.KerasApi;
@alexhiggins732
alexhiggins732 / download.bat
Created January 31, 2021 05:40
Download M3U8 TS with FFMPEG
ffmpeg -user_agent "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_5) AppleWebKit/601.7.8 (KHTML, like Gecko) Version/9.1.3 Safari/537.86.7" -i [Url to m3u8 file] -c copy nygard-16.mp4
@alexhiggins732
alexhiggins732 / gist:1c51dd185b0e27eb8d547d8d924c813e
Created January 24, 2021 04:07
Pulling from upstream master
If not set, add the upstream masters.
git remote add upstream https://github.com/iperov/DeepFaceLab.git
git pull upstream master
git status
git push origin master