Skip to content

KeyError in overlap handler #183

@bl-young

Description

@bl-young
df = stewicombo.combineInventoriesforFacilitiesinBaseInventory(
    base_inventory='TRI',
    inventory_dict = {'NEI': 2020,
                      'TRI': 2020,
                      'DMR': 2020,
                      'eGRID': 2020,
                      'GHGRP': 2020},
    download_if_missing=True
    )
Cell In[22], line 1
    df = df.drop(df_nans.index)

  File ~\.conda\envs\tiem_dev_latest\Lib\site-packages\pandas\core\frame.py:5581 in drop
    return super().drop(

  File ~\.conda\envs\tiem_dev_latest\Lib\site-packages\pandas\core\generic.py:4788 in drop
    obj = obj._drop_axis(labels, axis, level=level, errors=errors)

  File ~\.conda\envs\tiem_dev_latest\Lib\site-packages\pandas\core\generic.py:4830 in _drop_axis
    new_axis = axis.drop(labels, errors=errors)

  File ~\.conda\envs\tiem_dev_latest\Lib\site-packages\pandas\core\indexes\base.py:7070 in drop
    raise KeyError(f"{labels[mask].tolist()} not found in axis")

KeyError: '[381883, 381885, 381899, 381904, 381924, 381929, 381943, 381952, 381958, 381974, 381979, 381984, 381986, 382018, 382022, 382056, 382078, 382088, 382201, 382223, 382234, 382238, 382269, 382325, 382334, 382338, 382405, 382453, 382496, 382530, 382537, 382562, 382575, 382585] not found in axis'

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions