Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve error reporting #2

Open
smirarab opened this issue Jul 29, 2020 · 0 comments
Open

Improve error reporting #2

smirarab opened this issue Jul 29, 2020 · 0 comments

Comments

@smirarab
Copy link
Collaborator

When there is an error, give some indication to users what the error may be.

For example, if -b is forgotten, we get this. It is not informative

Warning: few calibration points were given. Set min_nleaf to 1 to maximize the number of possible initials
Traceback (most recent call last):
  File "/Users/smirarab/workspace/galaxy/.venv/bin/launch_wLogDate.py", line 7, in <module>
    exec(compile(f.read(), __file__, 'exec'))
  File "/Users/smirarab/Research/projects/ongoing/logdate/wLogDate/launch_wLogDate.py", line 97, in <module>
    main()
  File "/Users/smirarab/Research/projects/ongoing/logdate/wLogDate/launch_wLogDate.py", line 91, in main
    mu,f,x,s_tree,t_tree = logDate_with_random_init(tree,f_obj,sampling_time,bw_time=bw_time,root_time=tR,leaf_time=tL,nrep=nrep,min_nleaf=10,maxIter=maxIter,seed=randseed,pseudo=pseudo,seqLen=seqLen,verbose=verbose)
  File "/Users/smirarab/Research/projects/ongoing/logdate/wLogDate/logdate/logD_lib.py", line 194, in logDate_with_random_init
    X,seed,T0 = random_date_init(tree,smpl_times,nrep,min_nleaf=min_nleaf,seed=seed)
  File "/Users/smirarab/Research/projects/ongoing/logdate/wLogDate/logdate/fixed_init_lib.py", line 271, in random_date_init
    x0,t0 = get_random_initial(tree,random_subset,sampling_time)
  File "/Users/smirarab/Research/projects/ongoing/logdate/wLogDate/logdate/fixed_init_lib.py", line 224, in get_random_initial
    t0 = calibrate_set(tree,random_subset)
  File "/Users/smirarab/Research/projects/ongoing/logdate/wLogDate/logdate/fixed_init_lib.py", line 104, in calibrate_set
    date_from_root_and_leaves(node)
  File "/Users/smirarab/Research/projects/ongoing/logdate/wLogDate/logdate/fixed_init_lib.py", line 194, in date_from_root_and_leaves
    assert v.time < u.time
AssertionError
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant