<jupyter_start><jupyter_text>SummonUndead Raise armies of gibbering horrors, the easy waySometimes, when you're up in your Tower of Necromancy working on some evil,raising and leading armies of undead horrors on relatively small missions can be a real drag on your productivity. `SummonUndead` takes the hassle out of work-a-day necromantic battle magic, leaving you more time to focus onmentoring your mid-tier bosses, dungeon management, and other big-pictureproblems. Request for commentsShould we use `--exclusive`?<jupyter_code>%load_ext SummonUndead
%summon_undead
run_args = [ { 'index' : 0, 'x' : 10 },
             { 'index' : 1, 'x' : 11 },
             { 'index' : 2, 'x' : 23 },
             { 'index' : 3, 'x' : 34 },
             { 'index' : 4, 'x' : 13 },
             { 'index' : 5, 'x' : 55 },
             { 'index' : 6, 'x' : 73 },
             { 'index' : 7, 'x' : 21 },
             { 'index' : 8, 'x' : 18 } ]<jupyter_output><empty_output><jupyter_text>Sometimes, you want your army of undead to walk in single file and stay close to home.Use `local_serial` mode.<jupyter_code>%%moan --label foo -n 5 -i run_args -o x,y,index,pid --mode local_serial
import os
import time

time.sleep(.5)
y = x**2
pid = os.getpid()
foo_output<jupyter_output><empty_output><jupyter_text>Single file undead armies are mostly only useful for testing purposes.If you want them to shamble along in parallel formation, but still stayclose to your Tower of Necromancy, use `local_parallel` mode.<jupyter_code>%%moan --label bar -n 4 -i run_args -o x,y,index,pid --mode local_parallel
import os
import time

time.sleep(.5)
y = x**2
pid = os.getpid()
bar_output<jupyter_output><empty_output><jupyter_text>When it's time to turn your army of undead horrors loose on an unsuspectingHPC, use `slurm` mode. Make sure you provide a scratch directory visibleto all the nodes.<jupyter_code>%%moan --label baz -n 4 -i run_args -o x,y,index,pid --mode slurm --scratch=/global/projectb/scratch/ryneches/undead
import os
import time

time.sleep(.5)
y = x**2
pid = os.getpid()<jupyter_output>job submitted.<jupyter_text>(wait for jobs to finish)<jupyter_code>baz_output<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.11497938616582684, 'fraction_numerical': 0.016491067338524967, 'mean_word_length': 3.8211920529801326, 'pattern_counts': {'":': 0, '<': 20, '<?xml version=': 0, '>': 20, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '5', 'dir': 'jupyter-structured-clean-dedup', 'id': '611801', 'license': 'BSD-3-Clause', 'n_tokens_mistral': 782, 'n_tokens_neox': 731, 'n_words': 250, 'path': 'SummonUndead.ipynb', 'repo_name': 'ryneches/SummonUndead', 'size': '2183'}