Skip to content

Commit

Permalink
new modifications from remote development. includes adding some tex c…
Browse files Browse the repository at this point in the history
…omponents; maybe report(s) in hpc_lib.
  • Loading branch information
markyoder committed Jun 24, 2020
1 parent 535d53d commit 2176423
Show file tree
Hide file tree
Showing 5 changed files with 418 additions and 2,160 deletions.
12 changes: 7 additions & 5 deletions HPC_usage_analysis.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -51,22 +51,24 @@
},
{
"cell_type": "code",
"execution_count": 3,
"execution_count": 4,
"metadata": {},
"outputs": [],
"source": [
"# data_title = 'oneillm'\n",
"# data_title = 'serc'\n",
"data_title = 'hns'\n",
"data_title = 'serc'\n",
"#data_title = 'hns'\n",
"\n",
"#\n",
"# get header, print a few rows:\n",
"#data_file_name = 'data/sacct_out.out'\n",
"#data_file_name = 'data/sacct_mazama_out.out'\n",
"#data_file_name = 'data/sacct_sherlock_out_hns.out'\n",
"data_file_name = 'data/sacct/sherlock_out_{}.out'.format(data_title)\n",
"#\n",
"#data_file_name = 'data/sacct/sherlock_out_{}.out'.format(data_title)\n",
"#\n",
"#data_file_name = 'data/sacct_sherlock_out_oneillm.out'\n",
"#data_file_name = 'data/sacct_sherlock_out_serc.out'\n",
"data_file_name = 'data/sacct_serc_20200622.out'\n",
"#\n",
"demo_file = 'data/demo_data.out'\n",
"with open(data_file_name, 'r') as fin:\n",
Expand Down
6 changes: 3 additions & 3 deletions get_usage_mazama.sh
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
#!/bin/bash
#SBATCH -n 1
#SBATCH -o data/sacct_mazama_out.out
#SBATCH -e data/sacct_mazama_out.err
#SBATCH -o data/sacct_mazama_out_%j.out
#SBATCH -e data/sacct_mazama_out_%j.err

# can we pass "\t" correctly? maybe for now, just use the HPC standard "|" as a delimiter...
STARTTIME1="2019-10-15"
STARTTIME1="2019-12-01"
STARTTIME2="2019-12-15"
STARTTIME3="2020-04-01"

Expand Down
7 changes: 5 additions & 2 deletions hpc_lib.py
Original file line number Diff line number Diff line change
Expand Up @@ -812,7 +812,7 @@ def active_cpu_jobs_per_day_hour_report(self, qs=[.45, .5, .55], figsize=(14,10)
#ax2.plot(jobs_hourly['x'], jobs_hourly['mean'], ls='-', marker='o', label='PST')
ax2.plot((jobs_hourly['x']), jobs_hourly['mean'][ix_pst], ls='-', marker='o', label='UTC')
ax3.plot(jobs_weekly['x'], jobs_weekly['q_0.5'], ls='-', marker='o', color='b')
ax3.plot(jobs_weekly['x'], jobs_weekly['mean'], ls='--', marker='', color='b')
ax3.plot(jobs_weekly['x'], jobs_weekly['mean'], ls='--', marker='', color='b', label='mean')
ax3.fill_between(jobs_weekly['x'], jobs_weekly[qs_s[0]], jobs_weekly[qs_s[-1]],
alpha=.1, zorder=1, color='b')
#
Expand All @@ -821,7 +821,7 @@ def active_cpu_jobs_per_day_hour_report(self, qs=[.45, .5, .55], figsize=(14,10)
#ax5.plot(cpu_hourly['x'], cpu_hourly['mean'], ls='-', marker='o', label='PST')
ax5.plot( (cpu_hourly['x']), cpu_hourly['mean'][ix_pst], ls='-', marker='o', label='UTC')
ax6.plot(cpu_weekly['x'], cpu_weekly['q_0.5'], ls='-', marker='o', color='b')
ax6.plot(cpu_weekly['x'], cpu_weekly['mean'], ls='--', marker='', color='b')
ax6.plot(cpu_weekly['x'], cpu_weekly['mean'], ls='--', marker='', color='b', label='mean')
#
# TODO: can we simplyfy this qs syntax?
ax6.fill_between(cpu_weekly['x'], cpu_weekly[qs_s[0]], cpu_weekly[qs_s[-1]], alpha=.1, zorder=1, color='b')
Expand Down Expand Up @@ -1005,6 +1005,9 @@ def __init__(self, Short_title='HPC Analytics', Full_title='HPC Analitics Breakd
self.__dict__.update({key:val for key,val in locals().items() if not key in ('self', '__class__')})
#print('*** DEBUG: __init__: {}'.format(self.out_path))
#
if self.groups is None:
self.groups={'All':list(set(SACCT_obj.jobs_summary['User']))}
#
self.make_report()


Expand Down
2,550 changes: 400 additions & 2,150 deletions mazama_analytics_workbook.ipynb

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions tex_components/EARTH_Beamer_template.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
{"header": "%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\n% Stanford EARTH HPC Analytics template\n% v 1.0.0\n%\n% based (shamelessly() on:\n% Beamer Presentation\n% LaTeX Template\n% Version 1.0 (10/11/12)\n%\n% This template has been downloaded from:\n% http://www.LaTeXTemplates.com\n%\n% License:\n% CC BY-NC-SA 3.0 (http://creativecommons.org/licenses/by-nc-sa/3.0/)\n%\n%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%\n\n%----------------------------------------------------------------------------------------\n% PACKAGES AND THEMES\n%----------------------------------------------------------------------------------------\n\n\\documentclass{{beamer}}\n\n\\mode<presentation> {{\n\n% The Beamer class comes with a number of default slide themes\n% which change the colors and layouts of slides. Below this is a list\n% of all the themes, uncomment each in turn to see what they look like.\n\n%\\usetheme{{default}}\n%\\usetheme{{AnnArbor}}\n%\\usetheme{{Antibes}}\n%\\usetheme{{Bergen}}\n%\\usetheme{{Berkeley}}\n%\\usetheme{{Berlin}}\n%\\usetheme{{Boadilla}}\n%\\usetheme{{CambridgeUS}}\n%\\usetheme{{Copenhagen}}\n%\\usetheme{{Darmstadt}}\n%\\usetheme{{Dresden}}\n%\\usetheme{{Frankfurt}}\n%\\usetheme{{Goettingen}}\n%\\usetheme{{Hannover}}\n%\\usetheme{{Ilmenau}}\n%\\usetheme{{JuanLesPins}}\n%\\usetheme{{Luebeck}}\n\\usetheme{{Madrid}}\n%\\usetheme{{Malmoe}}\n%\\usetheme{{Marburg}}\n%\\usetheme{{Montpellier}}\n%\\usetheme{{PaloAlto}}\n%\\usetheme{{Pittsburgh}}\n%\\usetheme{{Rochester}}\n%\\usetheme{{Singapore}}\n%\\usetheme{{Szeged}}\n%\\usetheme{{Warsaw}}\n\n% As well as themes, the Beamer class has a number of color themes\n% for any slide theme. Uncomment each of these in turn to see how it\n% changes the colors of your current slide theme.\n\n%\\usecolortheme{{albatross}}\n%\\usecolortheme{{beaver}}\n%\\usecolortheme{{beetle}}\n%\\usecolortheme{{crane}}\n%\\usecolortheme{{dolphin}}\n%\\usecolortheme{{dove}}\n%\\usecolortheme{{fly}}\n%\\usecolortheme{{lily}}\n%\\usecolortheme{{orchid}}\n%\\usecolortheme{{rose}}\n%\\usecolortheme{{seagull}}\n%\\usecolortheme{{seahorse}}\n%\\usecolortheme{{whale}}\n%\\usecolortheme{{wolverine}}\n\n%\\setbeamertemplate{{footline}} % To remove the footer line in all slides uncomment this line\n%\\setbeamertemplate{{footline}}[page number] % To replace the footer line in all slides with a simple slide count uncomment this line\n\n%\\setbeamertemplate{{navigation symbols}}{{}} % To remove the navigation symbols from the bottom of all slides uncomment this line\n}}\n\n\\usepackage{{graphicx}} % Allows including images\n\\usepackage{{booktabs}} % Allows the use of \\toprule, \\midrule and \\bottomrule in tables\n\n",
"title": "%----------------------------------------------------------------------------------------\n% %TITLE PAGE\n%----------------------------------------------------------------------------------------\n\n\\title[{Short_title}]{{{Full_title}}} % The short title appears at the bottom of every slide, the full title is only on the title page\n\n\\author{{{author}}} % Your name\n\\institute[{institution_short}] % Your institution as it will appear on the bottom of every slide, may be shorthand to save space\n{{\n{institution} \\\\ % Your institution for the title page\n\\medskip\n\\textit{{{email}}} % Your email address\n}}\n\\date{{\\today}} % Date, can be changed to a custom date\n",
"figslide":"\\begin{{frame}}\n\\frametitle{{{fig_title}}}\n%Uncomment the code on this slide to include your own image from the same directory as the template .TeX file.\n\\begin{{figure}}\n\\includegraphics[width={width}\\linewidth]{{{fig_path}}}\n\\end{{figure}}\n\\end{{frame}}\n"}

0 comments on commit 2176423

Please sign in to comment.