Skip to content
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

Eco #166

Open
wants to merge 135 commits into
base: main
Choose a base branch
from
Open

Eco #166

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
135 commits
Select commit Hold shift + click to select a range
d2b68d9
testing git commands with few modifications on metrics.py
vcloitre Apr 27, 2015
781c9aa
testing git commands
vcloitre Apr 27, 2015
792dabe
testing git comands #3
vcloitre Apr 27, 2015
73302a3
testing git commands #4
vcloitre Apr 27, 2015
d7ac5ab
removed changes
vcloitre Apr 29, 2015
c7ab21f
fco metrics
vcloitre Apr 30, 2015
9851571
update
vcloitre Jul 1, 2015
c3e5e35
fix for raw_to_series
vcloitre Jul 1, 2015
ca21ca9
fix for raw_to_series
vcloitre Jul 1, 2015
376ede0
fix for raw_to_series
vcloitre Jul 1, 2015
cf9edcf
fix for raw_to_series
vcloitre Jul 1, 2015
a2bc133
Merge branch 'develop' of github.com:cyclus/cymetric into develop
vcloitre Aug 6, 2015
1a0b2f1
Merge branch 'develop' of github.com:vcloitre/cymetric into develop
vcloitre Aug 6, 2015
dae3224
diff with develop branch
vcloitre Aug 6, 2015
09025d0
add test file for cymetric/tools.py
vcloitre Aug 6, 2015
78269b0
add dbtest
vcloitre Aug 6, 2015
6b1f8d8
add dbtest
vcloitre Aug 6, 2015
56c2c4f
add dbtest
vcloitre Aug 6, 2015
bfc526b
add dbtest
vcloitre Aug 6, 2015
1ca6955
eco update
vcloitre Aug 6, 2015
8aeeac1
hashable dict
vcloitre Aug 6, 2015
a72f524
hashable dict
vcloitre Aug 6, 2015
0e04a20
hashable dict
vcloitre Aug 6, 2015
e12cd34
add prototype level to give facility costs
vcloitre Aug 10, 2015
c8c4131
add prototype level to give facility costs
vcloitre Aug 10, 2015
7b2b8c6
small fix
vcloitre Aug 10, 2015
3755dfd
small fix
vcloitre Aug 10, 2015
bf1836f
add prototype level
vcloitre Aug 10, 2015
e4181e4
small fix
vcloitre Aug 12, 2015
d6fde86
small fix
vcloitre Aug 12, 2015
7369b6b
changed test if reactor in capital cost
vcloitre Aug 12, 2015
ac6c316
small fix in period costs
vcloitre Aug 12, 2015
4fa4843
small fix in period costs
vcloitre Aug 12, 2015
e9cdc86
small fix
vcloitre Aug 12, 2015
a6fcbae
simulation lcoe fix
vcloitre Aug 12, 2015
98d1cdb
length of simulation annual costs
vcloitre Aug 13, 2015
14087b5
fuel costs not as a dict in EconomicInfo metric
vcloitre Aug 13, 2015
801a489
small fix
vcloitre Aug 13, 2015
95a0398
small fix
vcloitre Aug 13, 2015
72d3eb2
small fix
vcloitre Aug 13, 2015
2c9f352
small fix
vcloitre Aug 13, 2015
9f39096
small fix
vcloitre Aug 13, 2015
a23a260
minor fix
vcloitre Aug 13, 2015
d2b8a68
minor fix
vcloitre Aug 13, 2015
e679f91
minor fix
vcloitre Aug 13, 2015
78eb7bd
debugging
vcloitre Aug 13, 2015
dd0671b
bugs at institution level
vcloitre Aug 14, 2015
615f9d1
bugs at institution level
vcloitre Aug 14, 2015
9b23553
error institution pow gen
vcloitre Aug 14, 2015
1d32788
error institution pow gen
vcloitre Aug 14, 2015
635d961
add 'deviation' parameter for OM and fuel costs for random prices
vcloitre Aug 14, 2015
996a8da
add 'deviation' parameter for OM and fuel costs for random prices
vcloitre Aug 14, 2015
58afa80
add 'deviation' parameter for OM and fuel costs for random prices
vcloitre Aug 14, 2015
da094d5
add 'deviation' parameter for OM and fuel costs for random prices
vcloitre Aug 14, 2015
7b9dd7c
change from poisson to gaussian for deviation
vcloitre Aug 14, 2015
fd3895a
change from poisson to gaussian for deviation
vcloitre Aug 14, 2015
a772ac8
simpler calculations for lcoe
vcloitre Aug 16, 2015
a4272cf
simpler calculations for lcoe
vcloitre Aug 16, 2015
610bce4
simpler calculations for lcoe
vcloitre Aug 16, 2015
2a0b826
minor modifications
vcloitre Aug 19, 2015
82ce939
some file name changes
vcloitre Aug 20, 2015
d81536b
changes in files organisation
vcloitre Aug 20, 2015
b2ecb7c
minor fix
vcloitre Aug 20, 2015
e05ff39
minor fix
vcloitre Aug 20, 2015
4f28917
minor fix
vcloitre Aug 20, 2015
7fd45bf
some documentation
vcloitre Sep 3, 2015
fef913a
tests updates
vcloitre Sep 6, 2015
e0d2916
tests updates
vcloitre Sep 6, 2015
88fefc1
tests updates
vcloitre Sep 6, 2015
aeecb94
merging
bam241 Apr 20, 2020
134fff5
add back test-input
bam241 Apr 23, 2020
a26aa5d
adding matplotlib in CI
bam241 Apr 23, 2020
4b20628
adding matplotlib in CI
bam241 Apr 23, 2020
470171e
change eco_inputs for eco_tools
bam241 Apr 23, 2020
dea0aba
cleaning
bam241 Apr 23, 2020
574d133
not need of matplotlib
bam241 Apr 23, 2020
25a65fb
any better?
bam241 Apr 23, 2020
4d141b6
fix schema
bam241 Apr 23, 2020
9f818d9
fix schema (bis)
bam241 Apr 23, 2020
ad2f328
fix syntax
bam241 Apr 23, 2020
1630940
removing import cyclus
bam241 Apr 23, 2020
33d4336
fix schema
bam241 Apr 23, 2020
df7f3c5
fix schema
bam241 Apr 23, 2020
5a78b95
fix schema
bam241 Apr 23, 2020
f3e8303
fix schema
bam241 Apr 23, 2020
c4678a6
add missing column header
bam241 Apr 23, 2020
ca8d1a5
fixing syntax
bam241 Apr 23, 2020
180b102
fixing syntax
bam241 Apr 23, 2020
882851c
syntax fix
bam241 Apr 24, 2020
22952c0
syntax fix
bam241 Apr 24, 2020
8a919b6
extend table
bam241 Apr 24, 2020
aa8c375
replacing None per 0
bam241 Apr 24, 2020
2289361
syntax
bam241 Apr 24, 2020
4715f26
fixing table
bam241 Apr 24, 2020
3792db8
working simplified version of capital_cost
bam241 Apr 28, 2020
24ea521
fuel_cost
bam241 Apr 28, 2020
20ba917
working decomissionning cost
bam241 Apr 29, 2020
3f36ca8
formating
bam241 May 1, 2020
e6386e8
operation maintenance
bam241 May 1, 2020
73b1b50
syntax fixes
bam241 May 4, 2020
a6d7a5e
clean and fixed (again) CapitalCost
bam241 May 4, 2020
64909dc
starting xml parsing
bam241 May 21, 2020
6a32026
swtiching to yml parsing
bam241 May 21, 2020
bcfb2b7
adding a sample of the yaml file
bam241 May 21, 2020
0c6fe19
yaml reader working
bam241 May 22, 2020
347a2e1
capital_cost uses the new eco datas
bam241 May 26, 2020
ffde2af
inbetween
bam241 May 26, 2020
100404c
temp commit
bam241 May 26, 2020
9af8620
temp commit
bam241 May 26, 2020
4164ef3
almost building a df with facility properties
bam241 May 26, 2020
0d9dfaa
formating
bam241 May 27, 2020
1444672
add vsvode to gitignore
bam241 May 27, 2020
3c2a8b3
some addition formating
bam241 May 27, 2020
bf30820
Capital cost working with the new layout
bam241 May 27, 2020
3b34132
some formating and function fixing
bam241 May 29, 2020
00da475
fix line length
bam241 May 29, 2020
80fced2
fuel cost test working
bam241 Jun 1, 2020
aec936a
decommision working
bam241 Jun 1, 2020
2cadcca
fixing operation maintenance
bam241 Jun 2, 2020
fd020a4
fixing yml parsing
bam241 Jun 2, 2020
7a83ab3
some improvement in annual costs calculation
bam241 Jun 3, 2020
0812b94
working annual cost test
bam241 Jun 3, 2020
467bbda
various annual cost working and tested
bam241 Jun 8, 2020
c798d50
Merge remote-tracking branch 'upstream/master' into eco
bam241 Jun 9, 2020
13cb5e2
adding actualized costs
bam241 Jun 9, 2020
c953e44
average cost
bam241 Jun 10, 2020
c09af94
some progress
bam241 Jun 12, 2020
446516a
lcoe working
bam241 Jun 12, 2020
9ba52c0
some cleaning
bam241 Jun 12, 2020
87fdb9d
this is working
bam241 Jun 12, 2020
677a1d6
remove unsused vars
bam241 Jun 12, 2020
c8c0625
pyyaml is required for eco
bam241 Jun 12, 2020
6c0c1cc
reset metric.py formating
bam241 Jun 12, 2020
e438886
cleaning and adding pyyaml for nosetest
bam241 Jun 12, 2020
e2a3208
installing pyyaml after cache checkout
bam241 Jun 12, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -16,3 +16,4 @@ cymetric/typesystem.pyx
# Rever
rever/

.vscode
2 changes: 1 addition & 1 deletion circle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
- v1-repo-{{ checksum ".circle-sha" }}
- run:
name: Install nosetest
command: pip install nose
command: pip install nose pyyaml
- run:
name: Nosetests
command: nosetests -w ~/cymetric/tests; exit $?
Expand Down
4 changes: 4 additions & 0 deletions cymetric/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
from cymetric.evaluator import METRIC_REGISTRY, register_metric, \
raw_to_series, Evaluator, eval
from cymetric.execution import ExecutionContext, exec_code
from cymetric.eco_tools import swu
from cymetric.eco_metrics import capital_cost
except ImportError:
# again with the wacky CI issues
from .tools import dbopen
Expand All @@ -24,6 +26,8 @@
from .evaluator import METRIC_REGISTRY, register_metric, \
raw_to_series, Evaluator, eval
from .execution import ExecutionContext, exec_code
from .eco_tools import swu
from .eco_metrics import capital_cost

__version__ = '1.5.3'

41 changes: 41 additions & 0 deletions cymetric/eco_analysis.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
Performing economic analysis with the economic tools provided by Cymetric
=========================================================================


These are the main python files to perform an economic analysis using Cymetric :

| - eco_metrics.py
| - eco_tools.py
| - test_eco_metrics.py

Economic metrics calculation
----------------------------
eco_metrics.py has the same goal as metrics.py (ie it contains metrics), but it is only containing the economic metrics.
These metrics correspond to the reactor costs (construction costs, O&M costs, fuel costs and decommissioning costs).
Other functions allow the user to do more complex calculations (annual costs, LCOE...) and are written in eco_metrics.py as well. However, they are not actual metrics, because they do not have the @metric decorator. These are only functions whose results will not be stored in the output database (unlike the 'real' metrics with decorator).

Additional tools needed for analysis
------------------------------------
In order to support the calculations written in eco_metrics.py, some functions are stored in eco_tools.py.

Tests
-----
Tests are written in test_eco_metrics.py. The tests are inspired by test_metrics.py.

Using these functions
---------------------

In order to perform economic analysis, you can follow these steps :

1) Run your simulation with Cyclus

2) Write an xml file with the economic data needed to calculate the economic metrics and save it as 'parameters.xml' (see eco_parameters_frame.xml) in the same folder as the sqlite output database.

3) Calculate the different metrics you are interested in :

| - EconomicInfo to store the economic parameters needed for the economic analysis
| - CapitalCost to calculate the cash flows corresponding to the construction costs
| - OperationMaintenance to calculate the cash flows corresponding to the operations and maintenance costs
| - FuelCost to calculate the cash flows corresponding to the fuel costs
| - DecommissioningCost to calculate the costs corresponding to decommissionings occurring during the simulation

Loading