Personal tools
You are here: Home Discussion

Discussion

Up to the Bugs Forum
Please feel free to communicate anything you feel could help this project move on. You can receive an email each time a new message is posted by setting up your personal preferences.

Debug

Posted by obadmin at November 21. 2006
This is probably not a bug, but I'm not sure how to do it anyways. How do I turn off the "DEBUG:root: ..." and the "info:root: ..." messages that appear when I'm doing inference with OpenBayes?

Thanks for the help.
Posted by obadmin at November 21. 2006
Hello (unknown)

OpenBayes uses the python built-in logging module to print messages on the screen. You can turn them off and on as you wish, or even choose the details that will appear (e.g. Debug, info, warnings, critical,etc...)

to use the logging module I propose you to take a look at http://docs.python.org/lib/node407.html

If you just want to turn off the messages use the following commands AFTER importing OpenBayes:

import logging
logging.basicConfig(level= logging.NOTSET)

This should turn off most of the messages. However, some messages will still appear (this will be fixed in the next version which is coming out soon). To turn them off too, edit the openbayes files (especially inference.py) and whenever you find a line logging.basicConfig(level=logging.INFO) replace it with the above line : logging.basicConfig(level= logging.NOTSET). The logging commands are only found at the top of the files (no need to search the whole file)

cheers

Kosta


Powered by Ploneboard

Powered by Plone, the Open Source Content Management System

This site conforms to the following standards: