From 3c75b720d1755520bf31fe44553cc421802296a2 Mon Sep 17 00:00:00 2001 From: Bradlee Speice Date: Sun, 16 Oct 2022 20:37:21 -0400 Subject: [PATCH] Start on notebook --- .gitignore | 11 +-- .../2022-10-15-multicast/Multicast.ipynb | 69 +++++++++++++++++++ _notebooks/2022-10-15-multicast/run.sh | 24 +++++++ 3 files changed, 99 insertions(+), 5 deletions(-) create mode 100644 _notebooks/2022-10-15-multicast/Multicast.ipynb create mode 100755 _notebooks/2022-10-15-multicast/run.sh diff --git a/.gitignore b/.gitignore index 7cc94e0..ab952ef 100644 --- a/.gitignore +++ b/.gitignore @@ -1,7 +1,8 @@ -_site/ -.swp -.sass-cache/ -.jekyll-metadata .bundle/ -vendor/ +.ipynb_checkpoints/ +.jekyll-metadata +.sass-cache/ +.swp .vscode/ +_site/ +vendor/ diff --git a/_notebooks/2022-10-15-multicast/Multicast.ipynb b/_notebooks/2022-10-15-multicast/Multicast.ipynb new file mode 100644 index 0000000..77496ef --- /dev/null +++ b/_notebooks/2022-10-15-multicast/Multicast.ipynb @@ -0,0 +1,69 @@ +{ + "cells": [ + { + "cell_type": "markdown", + "id": "2bfdffd8", + "metadata": {}, + "source": [ + "# No More Magic: A Practical Introduction to Multicast\n", + "\n", + "Recent interaction - had a networking issue, likely required configuration tweaking, but:\n", + "\n", + "- Not a lot of people who knew how to diagnose\n", + "- Training people to diagnose is challenging\n", + "\n", + "I've said that [High Performance Systems aren't magical](/2019/07/high-performance-systems.html), but realization that for many topics, accessibility is problematic. If I _wanted_ to know more, I don't have any meaningful way to investigate beyond asking for someone's time. While manager's judgment call is fine (\"this isn't worth investigating further\"), I've had a lot of career \"upskilling\" learned from open source. Want to make sure that if other people are interested, there's a way to meaningfully engage with the topic." + ] + }, + { + "cell_type": "markdown", + "id": "d8cee425", + "metadata": {}, + "source": [ + "Add links for:\n", + "- Notebook source\n", + "- Script for running the notebook" + ] + }, + { + "cell_type": "code", + "execution_count": 3, + "id": "2edfbd79-d246-4b9a-a4a3-8e383c6b22a1", + "metadata": {}, + "outputs": [], + "source": [ + "#include \n", + "#include \n", + "#include \n", + "\n", + "auto run_parallel(std::initializer_list commands) {\n", + " \n", + "}\n", + "\n", + "std::vector threads{};\n", + "\n", + "for (auto command : commands)\n", + " threads.emplace_back([=]() { std::system(command); });\n", + "\n", + "for (auto& thread : threads)\n", + " thread.join();" + ] + } + ], + "metadata": { + "kernelspec": { + "display_name": "C++17", + "language": "C++17", + "name": "xcpp17" + }, + "language_info": { + "codemirror_mode": "text/x-c++src", + "file_extension": ".cpp", + "mimetype": "text/x-c++src", + "name": "c++", + "version": "17" + } + }, + "nbformat": 4, + "nbformat_minor": 5 +} diff --git a/_notebooks/2022-10-15-multicast/run.sh b/_notebooks/2022-10-15-multicast/run.sh new file mode 100755 index 0000000..bff1c80 --- /dev/null +++ b/_notebooks/2022-10-15-multicast/run.sh @@ -0,0 +1,24 @@ +SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd ) +mkdir -p "$SCRIPT_DIR"/notebook + +# Package pinning because of https://github.com/jupyter-xeus/xeus-cling/issues/415 +read -r -d '' RUN <