Skip to content

Commit

Permalink
FIX-#7201: Update docs on how to enable Modin logs for high-level API…
Browse files Browse the repository at this point in the history
… and low-level API (#7209)

Co-authored-by: Iaroslav Igoshev <Poolliver868@mail.ru>
Signed-off-by: arunjose696 <arunjose696@gmail.com>
  • Loading branch information
arunjose696 and YarShev authored Apr 22, 2024
1 parent e9dbcc1 commit b0b9ff1
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions docs/usage_guide/advanced_usage/modin_logging.rst
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,24 @@ Disable Modin logging like so:
# User code goes here
In Modin the lower-level functionality is logged in debug level, and higher level functionality in info level.
By default when logging is enabled in Modin, both high level and low level functionality are logged.
The below example script could be used to switch between logging all functions vs only logging higher level functions.
Setting logger level to ``logging.INFO`` logs only higher level functions.

.. code-block:: python
import modin.pandas as pd
from modin.logging.config import get_logger
from modin.config import LogMode
import logging
LogMode.enable()
logger = get_logger()
logger.setLevel(logging.INFO) # Replace with logger.setLevel(logging.DEBUG) for lower level logs
df = pd.DataFrame({'col1': [1, 2], 'col2': [3, 4]})
df = pd.concat([df, df])
Debugging from user defined functions:

.. warning::
Expand Down

0 comments on commit b0b9ff1

Please sign in to comment.