Pandas-profiling: OptionError: "No such keys(s): 'compute.use_numexpr'"

Created on 25 Nov 2019  路  4Comments  路  Source: pandas-profiling/pandas-profiling

Describe the bug

when i try to run the below code i get the following error

---------------------------------------------------------------------------
OptionError                               Traceback (most recent call last)
<ipython-input-21-c36b6aa52f32> in <module>()
      1 import pandas_profiling
----> 2 pandas_profiling.ProfileReport(bigdata)

C:\ProgramData\Anaconda3\lib\site-packages\pandas_profiling\__init__.py in __init__(self, df, **kwargs)
     66 
     67         # Get dataset statistics
---> 68         description_set = describe_df(df)
     69 
     70         # Get sample

C:\ProgramData\Anaconda3\lib\site-packages\pandas_profiling\model\describe.py in describe(df)
    538         with multiprocessing.pool.ThreadPool(pool_size) as executor:
    539             series_description = {}
--> 540             results = executor.starmap(multiprocess_1d, df.iteritems())
    541             for col, description in results:
    542                 series_description[col] = description

C:\ProgramData\Anaconda3\lib\multiprocessing\pool.py in starmap(self, func, iterable, chunksize)
    274         `func` and (a, b) becomes func(a, b).
    275         '''
--> 276         return self._map_async(func, iterable, starmapstar, chunksize).get()
    277 
    278     def starmap_async(self, func, iterable, chunksize=None, callback=None,

C:\ProgramData\Anaconda3\lib\multiprocessing\pool.py in get(self, timeout)
    655             return self._value
    656         else:
--> 657             raise self._value
    658 
    659     def _set(self, i, obj):

C:\ProgramData\Anaconda3\lib\multiprocessing\pool.py in worker(inqueue, outqueue, initializer, initargs, maxtasks, wrap_exception)
    119         job, i, func, args, kwds = task
    120         try:
--> 121             result = (True, func(*args, **kwds))
    122         except Exception as e:
    123             if wrap_exception and func is not _helper_reraises_exception:

C:\ProgramData\Anaconda3\lib\multiprocessing\pool.py in starmapstar(args)
     45 
     46 def starmapstar(args):
---> 47     return list(itertools.starmap(args[0], args[1]))
     48 
     49 #

C:\ProgramData\Anaconda3\lib\site-packages\pandas_profiling\model\describe.py in multiprocess_1d(column, series)
    390         A tuple with column and the series description.
    391     """
--> 392     return column, describe_1d(series)
    393 
    394 

C:\ProgramData\Anaconda3\lib\site-packages\pandas_profiling\model\describe.py in describe_1d(series)
    371         if series_description["type"] in type_to_func:
    372             series_description.update(
--> 373                 type_to_func[series_description["type"]](series, series_description)
    374             )
    375         else:

C:\ProgramData\Anaconda3\lib\site-packages\pandas_profiling\model\describe.py in describe_numeric_1d(series, series_description)
     60         "skewness": series.skew(),
     61         "sum": series.sum(),
---> 62         "mad": series.mad(),
     63         "n_zeros": (len(series) - np.count_nonzero(series)),
     64         "histogramdata": series,

C:\ProgramData\Anaconda3\lib\site-packages\pandas\core\generic.py in mad(self, axis, skipna, level)
   8775                     fill_value=fill_value,
   8776                     method=method,
-> 8777                     limit=limit,
   8778                     fill_axis=fill_axis,
   8779                 )

C:\ProgramData\Anaconda3\lib\site-packages\pandas\core\ops.py in wrapper(left, right)

C:\ProgramData\Anaconda3\lib\site-packages\pandas\core\ops.py in safe_na_op(lvalues, rvalues)

C:\ProgramData\Anaconda3\lib\site-packages\pandas\core\ops.py in na_op(x, y)

C:\ProgramData\Anaconda3\lib\site-packages\pandas\core\computation\expressions.py in <module>()
    167 
    168 # turn myself on
--> 169 set_use_numexpr(get_option("compute.use_numexpr"))
    170 
    171 

C:\ProgramData\Anaconda3\lib\site-packages\pandas\_config\config.py in __call__(self, *args, **kwds)
    231 
    232     def __call__(self, *args, **kwds):
--> 233         return self.__func__(*args, **kwds)
    234 
    235     @property

C:\ProgramData\Anaconda3\lib\site-packages\pandas\_config\config.py in _get_option(pat, silent)
    100 
    101 def _get_option(pat, silent=False):
--> 102     key = _get_single_key(pat, silent)
    103 
    104     # walk the nested dict

C:\ProgramData\Anaconda3\lib\site-packages\pandas\_config\config.py in _get_single_key(pat, silent)
     86         if not silent:
     87             _warn_if_deprecated(pat)
---> 88         raise OptionError("No such keys(s): {pat!r}".format(pat=pat))
     89     if len(keys) > 1:
     90         raise OptionError("Pattern matched multiple keys")

OptionError: "No such keys(s): 'compute.use_numexpr'

_Code:_ Preferably, use this code format:

import pandas_profiling
pandas_profiling.ProfileReport(bigdata)
    # Minimal reproducible code

Version information:

'2.3.0'

  • _Python version_: 3.7
  • _Environment_: Jupyter Notebook (local)
bug 馃悰

Most helpful comment

@Graygood Restart your system and it works!

All 4 comments

same here is there a workaround?

@Graygood Restart your system and it works!

Thanks for your answer @VellalaVineethKumar .

Thanks! It works @VellalaVineethKumar

Was this page helpful?
0 / 5 - 0 ratings

Related issues

TheMLman picture TheMLman  路  5Comments

romainx picture romainx  路  5Comments

shahanesanket picture shahanesanket  路  6Comments

jes08701 picture jes08701  路  6Comments

iolap-mmeyyappan picture iolap-mmeyyappan  路  3Comments