USEPA / ElectricityLCI

Creative Commons Zero v1.0 Universal
24 stars 10 forks source link

Add NETL methods, main.py, and YAML settings file #58

Closed gschivley closed 4 years ago

gschivley commented 4 years ago

This is a big PR with lots of changes. Some are smaller (docstrings on some of the existing EPA functions) but many are major.

New NETL methods:

Change the settings/config file file from JSON to YAML:

Add a main.py:

Other changes (not comprehensive):

gschivley commented 4 years ago

@WesIngwersen There are a few more changes from @jump2conclusionsmatt coming through on this PR but I wanted to get it in your queue. I didn't get as far with merging the two methods as I would have liked but I think we've made a significant push.

m-jamieson commented 4 years ago

In combinator.py, ln 17 and 20 'sheetname' must be replaced with 'sheet_name' because of pandas deprecation of sheetname

I'm getting an error in reading in EIA fuel receipts in read_eia_923_fuel_receipts File "C:\Users\wesle\AppData\Local\Programs\Python\Python37\lib\site-packages\xlrdinit.py", line 157, in open_workbook ragged_rows=ragged_rows, File "C:\Users\wesle\AppData\Local\Programs\Python\Python37\lib\site-packages\xlrd\book.py", line 92, in open_workbook_xls biff_version = bk.getbof(XL_WORKBOOK_GLOBALS) File "C:\Users\wesle\AppData\Local\Programs\Python\Python37\lib\site-packages\xlrd\book.py", line 1278, in getbof bof_error('Expected BOF record; found %r' % self.mem[savpos:savpos+8]) File "C:\Users\wesle\AppData\Local\Programs\Python\Python37\lib\site-packages\xlrd\book.py", line 1272, in bof_error raise XLRDError('Unsupported format, or corrupt file: ' + msg xlrd.biffh.XLRDError: Unsupported format, or corrupt file: Expected BOF record; found b'Plant Id'

Sorry about this - this has actually already been done in a pull request to Schivley's master that should automatically get pulled into this request on acceptance.

gschivley commented 4 years ago

I approved the PR by @jump2conclusionsmatt to this branch. Should be accessible here now.