diff --git a/predict/includes/functions.inc.php b/predict/includes/functions.inc.php index 1d21446..ae53f75 100644 --- a/predict/includes/functions.inc.php +++ b/predict/includes/functions.inc.php @@ -77,7 +77,7 @@ function runPred($pred_model) { // use `at` to automatically background the task $ph = popen("at now", "w"); - fwrite($ph, "cd /var/www/hab/predict/ && ./predict.py -v --latdelta=3 --londelta=3 -t ".$pred_model['timestamp']." --lat=".$predictor_lat." --lon=".$predictor_lon." " . $use_hd . $pred_model['uuid']); + fwrite($ph, "cd /var/www/hab/predict/ && ./predict.py -v --latdelta=3 --londelta=3 -p1 -f5 -t ".$pred_model['timestamp']." --lat=".$predictor_lat." --lon=".$predictor_lon." " . $use_hd . $pred_model['uuid']); fclose($ph); } diff --git a/predict/index.php b/predict/index.php index 4345c05..5ffe12c 100644 --- a/predict/index.php +++ b/predict/index.php @@ -50,8 +50,9 @@ function handlePred(pred_uuid) { $("#prediction_status").html("Downloading wind data..."); appendDebug("Prediction running with uuid: " + pred_uuid); appendDebug("Attempting to download GFS data for prediction"); + $("#input_form").hide("slide", { direction: "down" }, 500); + $("#map_canvas").fadeTo(1000, 0.2); // ajax to poll for progress - ajaxEventHandle = setInterval("getJSONProgress('"+pred_uuid+"')", 2000); appendDebug("Getting flight path from server...."); //getCSV(pred_uuid); @@ -94,6 +95,10 @@ function processProgress(progress) { $("#prediction_status").html(""); $("#prediction_progress").progressbar("options", "value", 0); $("#prediction_percent").html(""); + // bring the input form back up + $("#input_form").show("slide", { direction: "down" }, 500); + // un-fade the map canvas + $("#map_canvas").fadeTo(1500, 1); appendDebug("The predictor finished running."); // stop polling for JSON clearInterval(ajaxEventHandle); @@ -147,6 +152,7 @@ function initialize() { } } }); + //$("#input_form").draggable({containment: '#map_canvas'}); // if ( running_uuid != 0 ) handlePred(running_uuid); } @@ -252,7 +258,7 @@ function clearMapItems() { -
+