From a6d096f8890adbaddc6170e127b949c9cad85b72 Mon Sep 17 00:00:00 2001
From: Krish Moodbidri <krish94@uab.edu>
Date: Wed, 10 Aug 2022 15:12:42 -0500
Subject: [PATCH] V1 (#2)
* deleted form.js
* Edited template to work with cod cluster
* fixed ansys version
* edited form.yml and submit.yml.erb to be consistent with cheaha
* fixed ansys versions in form.yml
* removed variables in submit.yml.erb
* reverted submit.yml.erb changes
* fixed cluster name
* removed pascal node partition
* reverted pascal partition
---
form.js | 61 --------------------------------------------------
form.yml | 18 ++++++++++++---
submit.yml.erb | 7 ++++--
3 files changed, 20 insertions(+), 66 deletions(-)
delete mode 100644 form.js
diff --git a/form.js b/form.js
deleted file mode 100644
index 65d8c46..0000000
--- a/form.js
+++ /dev/null
@@ -1,61 +0,0 @@
-'use strict'
-
-/**
- * Fix num cores, allowing blanks to remain
- */
-function fix_num_cores() {
- let node_type_input = $('#batch_connect_session_context_node_type');
- let node_type = node_type_input.val();
- let num_cores_input = $('#num_cores');
-
- if(num_cores_input.val() === '') {
- return;
- }
-
- if(node_type === 'hugemem') {
- set_ppn_owens_hugemem(num_cores_input);
- } else {
- set_ppn_owens_regular(num_cores_input);
- }
-}
-
-/**
- * Sets the PPN limits available for Owens hugemem nodes.
- *
- * hugemem reservations are always assigned the full node
- *
- * @param {element} num_cores_input The input for num_cores
- */
-function set_ppn_owens_hugemem(num_cores_input) {
- const NUM_CORES = 48;
- num_cores_input.attr('max', NUM_CORES);
- num_cores_input.attr('min', NUM_CORES);
- num_cores_input.val(NUM_CORES);
-}
-
-/**
- * Sets the PPN limits available for non hugemem Owens nodes.
- *
- * @param {element} num_cores_input The input for num_cores
- */
-function set_ppn_owens_regular(num_cores_input) {
- const NUM_CORES = 28;
- num_cores_input.attr('max', NUM_CORES);
- num_cores_input.attr('min', 1);
- num_cores_input.val(Math.min(NUM_CORES, num_cores_input.val()));
-}
-
-
-/**
- * Change the maximum number of cores selected.
- */
-function set_node_type_change_handler() {
- let node_type_input = $('#batch_connect_session_context_node_type');
- node_type_input.change(node_type_input, fix_num_cores);
-}
-
-$(document).ready(function() {
- // Set the max value to be what was set in the last session
- fix_num_cores();
- set_node_type_change_handler();
-});
\ No newline at end of file
diff --git a/form.yml b/form.yml
index 92fcda1..a7ba01f 100644
--- a/form.yml
+++ b/form.yml
@@ -1,5 +1,5 @@
---
-cluster: "{{ cluster_name }}"
+cluster: "SLURM_CLUSTER"
attributes:
bc_num_hours:
value: 1
@@ -23,14 +23,26 @@ attributes:
widget: select
label: Partition
options:
- - [ "low", "low" ]
+ - [ "express", "express" ]
+ - [ "short", "short" ]
+ - [ "medium", "medium" ]
+ - [ "long", "long" ]
+ - [ "interactive", "interactive" ]
+ - [ "pascalnodes", "pascalnodes" ]
+ - [ "pascalnodes-medium", "pascalnodes-medium" ]
+ - [ "largemem", "largemem" ]
+ - [ "largemem-long", "largemem-long" ]
+ - [ "amd-hdr100", "amd-hdr100" ]
version:
widget: select
label: "ANSYS version"
help: "This defines the version of ANSYS you want to load."
options:
- - [ "19.1", "ANSYS/19.1" ]
+ - [ "2021R1", "ANSYS/2021R1" ]
+ - [ "2020R2", "ANSYS/2020R2" ]
+ - [ "2020R1", "ANSYS/2020R1" ]
+
form:
- version
- bc_num_hours
diff --git a/submit.yml.erb b/submit.yml.erb
index 8b17d32..db4d0e9 100644
--- a/submit.yml.erb
+++ b/submit.yml.erb
@@ -1,6 +1,6 @@
---
batch_connect:
- template: vnc
+ template: "vnc"
script:
native:
- "-N 1"
@@ -8,4 +8,7 @@ script:
- "--mem-per-cpu=<%= bc_num_mems.blank? ? 4 : bc_num_mems.to_i %>G"
- "--partition=<%= bc_partition %>"
- "--time=<%= bc_num_hours.blank? ? 1 : bc_num_hours.to_i %>:00:00"
-
+ - "--job-name=ood-{{ ansys_module_name|lower }}"
+<%- if bc_partition.include? "pascalnodes" -%>
+ - "--gres=gpu:1"
+<%- end -%>
--
GitLab