-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
2024 spreadsheet updates #6
Conversation
* correct coal num_tds to account for igcc w/ ccs * Add coal cases, commit errata data
…eadsheet_updates
…-flight 2024 data
@@ -230,7 +231,7 @@ def calculate_all_debt_fractions(data_workbook_filename: str, output_filename: s | |||
OUTPUT_FILENAME - File to save calculated debt fractions to. Should end with .csv | |||
""" | |||
tech_map: Dict[str, Type[TechProcessor]] = {tech.__name__: tech for tech in LCOE_TECHS} | |||
techs = LCOE_TECHS if tech is None else [tech_map[tech]] | |||
techs = [lcoe_calculator.tech_processors.UtilityPvPlusBatteryProc] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this correct?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It is not. Looks like I forgot to update this file after getting things working in lcoe calculator. I'll convert the PR to draft.
lcoe_calculator/base_processor.py
Outdated
@@ -99,7 +99,7 @@ def tech_name(self) -> str: | |||
dscr: float|None = None # Debt service coverage ratio (unitless, typically 1-1.5) | |||
|
|||
def __init__(self, data_workbook_fname: str, case: str = MARKET_FIN_CASE, | |||
crp: CrpChoiceType = 30, extractor: Type[AbstractExtractor] = Extractor): | |||
crp: CrpChoiceType = 30, tcc : str = None, extractor: Type[AbstractExtractor] = Extractor): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should be tcc: Optional[str] = None
lcoe_calculator/base_processor.py
Outdated
itc = self._calc_itc() | ||
|
||
# Trim the first year to eliminate pre-inflation reduction act confusion |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this "trim first year" or is it more of "trim year 20XX"? Will this still be valid next year?
lcoe_calculator/extractor.py
Outdated
@@ -30,14 +30,16 @@ class Extractor(AbstractExtractor): | |||
tax_credits_sheet = 'Tax Credits' | |||
|
|||
def __init__(self, data_workbook_fname: str, sheet_name: str, case: str, crp: CrpChoiceType, | |||
scenarios: List[str], base_year: int): | |||
scenarios: List[str], base_year: int, tax_credit_case : str = None): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is starting to stretch my OOP knowledge, but if tax_credit_case is only used in the child class, I think it can (and should) be left out of the parent constructor. Does that sound right? Also use Optional[str] for the tcc type.
""" | ||
@param data_workbook_fname - IGNORED | ||
@param sheet_name - IGNORED | ||
@param case - 'Market' or 'R&D' | ||
@param crp - capital recovery period: 20, 30, or 'TechLife' | ||
@param scenarios - IGNORED | ||
@param base_year - IGNORED | ||
@param tax_credit_case - IGNORED, only used by PV+Battery |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
❤️
…so handle subset of dates for Nuclear. Some PR comments addressed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
Changes: