mirror of
https://github.com/newnius/YAO-portal.git
synced 2025-06-06 07:11:54 +00:00
add model_dir & output_dir
This commit is contained in:
parent
dd559b06a2
commit
c5ff8953b9
2
ajax.php
2
ajax.php
@ -74,6 +74,8 @@ switch ($action) {
|
||||
$job->set('name', cr_get_POST('name', 'jobName'));
|
||||
$job->set('virtual_cluster', cr_get_POST('cluster'));
|
||||
$job->set('workspace', cr_get_POST('workspace'));
|
||||
$job->set('model_dir', cr_get_POST('model_dir'));
|
||||
$job->set('output_dir', cr_get_POST('output_dir'));
|
||||
$job->set('priority', cr_get_POST('priority'));
|
||||
$job->set('run_before', cr_get_POST('run_before'));
|
||||
$job->set('locality', cr_get_POST('locality'));
|
||||
|
@ -36,6 +36,8 @@ function job_submit(CRObject $job)
|
||||
}
|
||||
$job->set('tasks', $tasks);
|
||||
$job->set('workspace', $job->get('workspace'));
|
||||
$job->set('model_dir', $job->get('model_dir'));
|
||||
$job->set('output_dir', $job->get('output_dir'));
|
||||
$job->set('group', $job->get('virtual_cluster'));
|
||||
$job->set('priority', $job->getInt('priority'));
|
||||
$job->set('locality', $job->getInt('locality'));
|
||||
|
29
modals.php
29
modals.php
@ -89,6 +89,18 @@
|
||||
<option value="">None</option>
|
||||
</select>
|
||||
</div>
|
||||
<label>Model Dir</label>
|
||||
<div class="form-group form-group-lg">
|
||||
<label for="form-job-model-dir" class="sr-only">Model Dir</label>
|
||||
<input type="text" id="form-job-model-dir" class="form-control" maxlength="256"
|
||||
placeholder="Dir for model checkpoints" required/>
|
||||
</div>
|
||||
<label>Output Dir</label>
|
||||
<div class="form-group form-group-lg">
|
||||
<label for="form-job-output-dir" class="sr-only">Workspace</label>
|
||||
<input type="text" id="form-job-output-dir" class="form-control" maxlength="256"
|
||||
placeholder="Dir for result data" required/>
|
||||
</div>
|
||||
<label>Queue</label>
|
||||
<div class="form-group form-group-lg">
|
||||
<label for="form-job-cluster" class="sr-only">Virtual Cluster</label>
|
||||
@ -136,17 +148,6 @@
|
||||
<input type="text" class="form-control task-image" maxlength=""
|
||||
value="quickdeploy/yao-tensorflow:1.14-gpu"
|
||||
placeholder="quickdeploy/yao-tensorflow:1.14-gpu"/>
|
||||
<!--
|
||||
<select title="docker image" class="form-control form-control task-image" required>
|
||||
<option value="nvidia/cuda:9.0-base">nvidia/cuda:9.0-base</option>
|
||||
<option value="quickdeploy/yao-tensorflow:1.14-gpu" selected>
|
||||
quickdeploy/yao-tensorflow:1.14-gpu
|
||||
</option>
|
||||
<option value="quickdeploy/yao-tensorflow:2.1-gpu">
|
||||
quickdeploy/yao-tensorflow:2.1-gpu
|
||||
</option>
|
||||
</select>
|
||||
-->
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<label>CMD</label>
|
||||
@ -171,8 +172,10 @@
|
||||
<div class="col-md-2">
|
||||
<label>Node Role<abbr title="Node role">?</abbr></label>
|
||||
<select class="form-control form-control task-is-ps" required>
|
||||
<option value="1">PS</option>
|
||||
<option value="0" selected>Worker</option>
|
||||
<option value="1">Parameter Server</option>
|
||||
<option value="0">Worker</option>
|
||||
<option value="0" selected>Default</option>
|
||||
<option value="0">Reducer</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-md-2">
|
||||
|
@ -110,6 +110,8 @@ function register_events_job() {
|
||||
$("#form-job-predict-time").click(function (e) {
|
||||
var name = $('#form-job-name').val();
|
||||
var workspace = $('#form-job-workspace').val();
|
||||
var model_dir = $('#form-job-model_dir').val();
|
||||
var output_dir = $('#form-job-output_dir').val();
|
||||
var cluster = $('#form-job-cluster').val();
|
||||
var priority = $('#form-job-priority').val();
|
||||
var run_before = $('#form-job-run-before').val();
|
||||
@ -148,6 +150,8 @@ function register_events_job() {
|
||||
data: {
|
||||
name: name,
|
||||
workspace: workspace,
|
||||
model_dir: model_dir,
|
||||
output_dir: output_dir,
|
||||
cluster: cluster,
|
||||
priority: priority,
|
||||
run_before: run_before,
|
||||
@ -246,7 +250,7 @@ function load_jobs(scope) {
|
||||
$("#table-job").bootstrapTable({
|
||||
url: 'service?action=job_list&who=' + scope,
|
||||
responseHandler: jobResponseHandler,
|
||||
sidePagination: 'server',
|
||||
sidePagination: 'client',
|
||||
cache: true,
|
||||
striped: true,
|
||||
pagination: true,
|
||||
@ -393,10 +397,7 @@ var statusFormatter = function (status) {
|
||||
|
||||
function jobResponseHandler(res) {
|
||||
if (res['errno'] === 0) {
|
||||
var tmp = {};
|
||||
tmp["total"] = res["count"];
|
||||
tmp["rows"] = res["jobs"];
|
||||
return tmp;
|
||||
return res["jobs"];
|
||||
}
|
||||
$("#modal-msg-content").html(res["msg"]);
|
||||
$("#modal-msg").modal('show');
|
||||
|
@ -56,11 +56,11 @@ if (isset($_GET['logs'])) {
|
||||
$entries = array(
|
||||
array('summary', 'Summary'),
|
||||
array('jobs', 'Jobs'),
|
||||
array('workspaces', 'Workspaces'),
|
||||
array('workspaces', 'Projects'),
|
||||
array('logs', 'Activities'),
|
||||
array('resources', 'Admin:Resources'),
|
||||
array('agents', 'Admin:Agents'),
|
||||
array('clusters', 'Admin:Virtual Clusters'),
|
||||
//array('agents', 'Admin:Agents'),
|
||||
array('clusters', 'Admin:Queues'),
|
||||
array('logs_all', 'Admin:Audit')
|
||||
);
|
||||
$visible_entries = array();
|
||||
|
Loading…
Reference in New Issue
Block a user