improved tmp file handling
This commit is contained in:
parent
b5acc03a1c
commit
d498986619
@ -412,13 +412,6 @@
|
|||||||
|
|
||||||
:- problog_define_flag(maxsteps, problog_flag_validate_posint, 'max. number of prob. steps per derivation', 1000, inference).
|
:- problog_define_flag(maxsteps, problog_flag_validate_posint, 'max. number of prob. steps per derivation', 1000, inference).
|
||||||
|
|
||||||
%%%%%%%%%%%%
|
|
||||||
% montecarlo: recalculate current approximation after N samples
|
|
||||||
% montecarlo: write log to this file
|
|
||||||
%%%%%%%%%%%%
|
|
||||||
|
|
||||||
:- problog_define_flag(mc_logfile, problog_flag_validate_file, 'logfile for montecarlo', 'log.txt', mcmc).
|
|
||||||
|
|
||||||
%%%%%%%%%%%%
|
%%%%%%%%%%%%
|
||||||
% BDD timeout in seconds, used as option in BDD tool
|
% BDD timeout in seconds, used as option in BDD tool
|
||||||
% files to write BDD script and pars
|
% files to write BDD script and pars
|
||||||
@ -431,13 +424,9 @@
|
|||||||
|
|
||||||
%:- problog_define_flag(bdd_path, problog_flag_validate_directory, 'problogbdd directory', '.',bdd).
|
%:- problog_define_flag(bdd_path, problog_flag_validate_directory, 'problogbdd directory', '.',bdd).
|
||||||
:- problog_define_flag(bdd_time, problog_flag_validate_posint, 'BDD computation timeout in seconds', 60, bdd).
|
:- problog_define_flag(bdd_time, problog_flag_validate_posint, 'BDD computation timeout in seconds', 60, bdd).
|
||||||
:- problog_define_flag(bdd_par_file, problog_flag_validate_file, 'file for BDD variable parameters', example_bdd_probs, bdd).
|
|
||||||
:- problog_define_flag(bdd_result, problog_flag_validate_file, 'file to store result calculated from BDD', example_bdd_res, bdd).
|
|
||||||
:- problog_define_flag(bdd_file, problog_flag_validate_file, 'file for BDD script', example_bdd, bdd, flags:bdd_file_handler).
|
|
||||||
:- problog_define_flag(save_bdd, problog_flag_validate_boolean, 'save BDD files for (last) lower bound', false, bdd).
|
:- problog_define_flag(save_bdd, problog_flag_validate_boolean, 'save BDD files for (last) lower bound', false, bdd).
|
||||||
:- problog_define_flag(dynamic_reorder, problog_flag_validate_boolean, 'use dynamic re-ordering for BDD', true, bdd).
|
:- problog_define_flag(dynamic_reorder, problog_flag_validate_boolean, 'use dynamic re-ordering for BDD', true, bdd).
|
||||||
:- problog_define_flag(bdd_static_order, problog_flag_validate_boolean, 'use a static order', false, bdd).
|
:- problog_define_flag(bdd_static_order, problog_flag_validate_boolean, 'use a static order', false, bdd).
|
||||||
:- problog_define_flag(static_order_file, problog_flag_validate_file, 'file for BDD static order', example_bdd_order, bdd).
|
|
||||||
|
|
||||||
|
|
||||||
%%%%%%%%%%%%
|
%%%%%%%%%%%%
|
||||||
@ -482,6 +471,7 @@ init_global_params :-
|
|||||||
% working directory: all the temporary and output files will be located there
|
% working directory: all the temporary and output files will be located there
|
||||||
% it assumes a subdirectory of the current working dir
|
% it assumes a subdirectory of the current working dir
|
||||||
% on initialization, the current dir is the one where the user's file is located
|
% on initialization, the current dir is the one where the user's file is located
|
||||||
|
% should be changed to use temporary folder structure of operating system
|
||||||
%%%%%%%%%%%%
|
%%%%%%%%%%%%
|
||||||
problog_define_flag(dir, problog_flag_validate_directory, 'directory for files', WorkDir, output),
|
problog_define_flag(dir, problog_flag_validate_directory, 'directory for files', WorkDir, output),
|
||||||
check_existance('problogbdd').
|
check_existance('problogbdd').
|
||||||
@ -497,6 +487,19 @@ check_existance(FileName):-
|
|||||||
% parameter initialization to be called after returning to user's directory:
|
% parameter initialization to be called after returning to user's directory:
|
||||||
:- initialization(init_global_params).
|
:- initialization(init_global_params).
|
||||||
|
|
||||||
|
:- problog_define_flag(bdd_par_file, problog_flag_validate_file, 'file for BDD variable parameters', example_bdd_probs, bdd).
|
||||||
|
:- problog_define_flag(bdd_result, problog_flag_validate_file, 'file to store result calculated from BDD', example_bdd_res, bdd).
|
||||||
|
:- problog_define_flag(bdd_file, problog_flag_validate_file, 'file for BDD script', example_bdd, bdd, flags:bdd_file_handler).
|
||||||
|
:- problog_define_flag(static_order_file, problog_flag_validate_file, 'file for BDD static order', example_bdd_order, bdd).
|
||||||
|
|
||||||
|
%%%%%%%%%%%%
|
||||||
|
% montecarlo: recalculate current approximation after N samples
|
||||||
|
% montecarlo: write log to this file
|
||||||
|
%%%%%%%%%%%%
|
||||||
|
|
||||||
|
:- problog_define_flag(mc_logfile, problog_flag_validate_file, 'logfile for montecarlo', 'log.txt', mcmc).
|
||||||
|
|
||||||
|
|
||||||
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
|
||||||
% internal control flags
|
% internal control flags
|
||||||
% if on
|
% if on
|
||||||
|
Reference in New Issue
Block a user