-
Notifications
You must be signed in to change notification settings - Fork 135
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* new short forward sampling presentation * updated some scgpc inputs and added adaptive * completed example of forward sampling exercise 5 for the short workshop format added * advanced sampling presentation and exercises * add presentation slides from RAVEN 2022 workshop * add raven installation slides * added TSA, CodeInterfaces workshop docs * add slides for Ensemble and Hybrid model * add presentation templates * add DSS slides * add Bayesian Calibration slides * edit slides * added raven models slideset * edits slides * modified test names and revisions * moved subfolders * changed order to reflect order of appearance in the introduction of the Model sections * plot entity * model order * added starting models * Apply suggestions from code review --------- Co-authored-by: Congjian Wang - INL <congjian.wang@inl.gov> * Arbitrary Custom Input in InputSpec (#2332) * added custom arbitrary input extention to inputspecs and unit test * removing internalParallel for adaptsobol cluster test * switching ylabel to subplot titles, helps when a lot of subplots * changed varname to ylabel, but split up long names by underscores: * Update FARM user manual and citation (#2333) * Update FARM user manual and citation * Remove space. * Revert previous. --------- * adding sparse sensing hands on files * changing marker color and adding the presentation * adding latest presentations * moving hands-on session mid presentation * reduce ppt sizes * reduce ppts sizes --------- Co-authored-by: Congjian Wang <congjian.wang@inl.gov> Co-authored-by: Diego Mandelli <diego.mandelli@inl.gov> Co-authored-by: Andrea Alfonsi - NuCube <aalfonsi@nucube.energy> Co-authored-by: Gabriel J. Soto <Gabriel.SotoGonzalez@inl.gov> Co-authored-by: Haoyu Wang <63424217+wanghy-anl@users.noreply.github.com> Co-authored-by: Joshua J. Cogliati <joshua.cogliati@inl.gov> Co-authored-by: Jimmy-INL <mohammad.abdo@inl.gov>
- Loading branch information
1 parent
9d1fcb1
commit 6a89f3b
Showing
64 changed files
with
17,296 additions
and
16 deletions.
There are no files selected for viewing
Binary file not shown.
Binary file not shown.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
Power (W),BCTemperature (K),filename | ||
350,240,350_240.csv | ||
350,270,350_270.csv | ||
350,300,350_300.csv | ||
350,330,350_330.csv |
108 changes: 108 additions & 0 deletions
108
doc/workshop/SparseSensing/exercises/testSPSLOptiTwist.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,108 @@ | ||
<?xml version="1.0" ?> | ||
<Simulation verbosity="debug"> | ||
<TestInfo> | ||
<name>tests/framework/Postprocessors/SparseSensing</name> | ||
<author>Mohammad Abdo (@Jimmy-INL)</author> | ||
<created>2022-07-18</created> | ||
<classesTested>Models.Postprocessors.SparseSensing</classesTested> | ||
<description>This test aims to check the ability of the Sparse Sensing Postprocessor | ||
to locate and plot the selected sensors to reconstruct the temperature field of the OPTI-TWIST prototype | ||
when perturbing the heater power. | ||
</description> | ||
</TestInfo> | ||
|
||
<RunInfo> | ||
<WorkingDir>reconstructionOptiTwist</WorkingDir> | ||
<Sequence>LoadCSV, mySPpp, print</Sequence> | ||
<batchSize>1</batchSize> | ||
</RunInfo> | ||
|
||
<Files> | ||
<Input name="twistFile" type=""></Input><!-- Provide the csv file that contains the names of the samples files--> | ||
<Input name="refDO" type=""></Input><!-- Provide the csv of the case onwhich you want to show the sensors i.e., maximum initial power (350 W) and maximum initial Temperature--> | ||
</Files> | ||
|
||
<Steps> | ||
<IOStep name="LoadCSV"> | ||
<Input class="Files" type="">twistFile</Input> | ||
<Input class="Files" type=""></Input><!--Fill in--> | ||
<Output class="DataObjects" type="HistorySet">TwistDO</Output> | ||
<Output class="DataObjects" type="PointSet">myDO</Output> | ||
</IOStep> | ||
<PostProcess name="mySPpp"> | ||
<Input class="DataObjects" type="HistorySet">TwistDO</Input> | ||
<Model class="Models" type="PostProcessor"></Model><!--Fill in--> | ||
<Output class="DataObjects" type="DataSet">outPP</Output> | ||
</PostProcess> | ||
<IOStep name="print"> | ||
<Input class="DataObjects" type="DataSet">outPP</Input> | ||
<Input class="DataObjects" type="PointSet">myDO</Input> | ||
<Input class="DataObjects" type="HostorySet">TwistDO</Input> | ||
<Output class="OutStreams" type="Print">outPP</Output> | ||
<Output class="OutStreams" type="Plot">mySensorPlot</Output> | ||
</IOStep> | ||
</Steps> | ||
|
||
<Models> | ||
<PostProcessor name="mySPSL" subType="SparseSensing" verbosity="debug"> | ||
<Goal subType=""> <!--Fill in--> | ||
<features></features><!--Fill in att variable names needed for training from the CSV--> | ||
<target>Temperature (K)</target> | ||
<basis>SVD</basis> | ||
<nModes></nModes> <!--Try different modes--> | ||
<nSensors></nSensors> <!--Try different number of sensors--> | ||
<optimizer>QR</optimizer> | ||
</Goal> | ||
</PostProcessor> | ||
</Models> | ||
|
||
<DataObjects> | ||
<PointSet name="myDO"> | ||
<Output>X (m),Temperature (K),Y (m)</Output> | ||
</PointSet> | ||
<HistorySet name="TwistDO"> | ||
<Input> Power (W), BCTemperature (K)</Input> | ||
<Output>X (m),Temperature (K),Y (m)</Output> | ||
<options> | ||
<pivotParameter>index</pivotParameter> | ||
</options> | ||
</HistorySet> | ||
<DataSet name="outPP"> | ||
<Input>InputPlaceHolder</Input> | ||
<Output>Temperature (K), X (m), Y (m)</Output> | ||
<Index var="sensor">X (m),Y (m),Temperature (K)</Index> | ||
</DataSet> | ||
</DataObjects> | ||
|
||
<OutStreams> | ||
<Print name="outPP"> | ||
<type>csv</type> | ||
<source>outPP</source> | ||
<what>output</what> | ||
</Print> | ||
<Plot name="mySensorPlot"> | ||
<plotSettings> | ||
<plot> | ||
<type>scatter</type> | ||
<x>myDO|Output|X (m)</x> | ||
<y>myDO|Output|Y (m)</y> | ||
<cmap>coolwarm</cmap> | ||
<colorMap>myDO|Output|Temperature (K)</colorMap> | ||
</plot> | ||
<plot> | ||
<type>scatter</type> | ||
<x>outPP|Output|X (m)</x> | ||
<y>outPP|Output|Y (m)</y> | ||
<c>magenta</c> | ||
<marker>*</marker> | ||
</plot> | ||
<xlabel>x</xlabel> | ||
<ylabel>y</ylabel> | ||
</plotSettings> | ||
<actions> | ||
<how>png</how> | ||
</actions> | ||
</Plot> | ||
</OutStreams> | ||
|
||
</Simulation> |
Binary file added
BIN
+125 KB
...rseSensing/inputs/gold/reconstructionOptiTwist/mySensorPlot_scatter-scatter.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions
5
doc/workshop/SparseSensing/inputs/gold/reconstructionOptiTwist/outPP.csv
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
sensor,Temperature (K),X (m),Y (m) | ||
1,241.2203563,0.037571896,-0.354205816 | ||
2,243.0797253,0.002587661,-0.127088999 | ||
3,240.0000001,0.037667017,0.479859575 | ||
4,243.6755973,0.000149014,0.051719659 |
108 changes: 108 additions & 0 deletions
108
doc/workshop/SparseSensing/inputs/testSPSLOptiTwist.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,108 @@ | ||
<?xml version="1.0" ?> | ||
<Simulation verbosity="debug"> | ||
<TestInfo> | ||
<name>tests/framework/Postprocessors/SparseSensing</name> | ||
<author>Mohammad Abdo (@Jimmy-INL)</author> | ||
<created>2022-07-18</created> | ||
<classesTested>Models.Postprocessors.SparseSensing</classesTested> | ||
<description>This test aims to check the ability of the Sparse Sensing Postprocessor | ||
to locate and plot the selected sensors to reconstruct the temperature field of the OPTI-TWIST prototype | ||
when perturbing the heater power. | ||
</description> | ||
</TestInfo> | ||
|
||
<RunInfo> | ||
<WorkingDir>reconstructionOptiTwist</WorkingDir> | ||
<Sequence>LoadCSV, mySPpp, print</Sequence> | ||
<batchSize>1</batchSize> | ||
</RunInfo> | ||
|
||
<Files> | ||
<Input name="twistFile" type="">../../data//Perturbations.csv</Input> | ||
<Input name="refDO" type="">../../data/350_330.csv</Input> | ||
</Files> | ||
|
||
<Steps> | ||
<IOStep name="LoadCSV"> | ||
<Input class="Files" type="">twistFile</Input> | ||
<Input class="Files" type="">refDO</Input> | ||
<Output class="DataObjects" type="HistorySet">TwistDO</Output> | ||
<Output class="DataObjects" type="PointSet">myDO</Output> | ||
</IOStep> | ||
<PostProcess name="mySPpp"> | ||
<Input class="DataObjects" type="HistorySet">TwistDO</Input> | ||
<Model class="Models" type="PostProcessor">mySPSL</Model> | ||
<Output class="DataObjects" type="DataSet">outPP</Output> | ||
</PostProcess> | ||
<IOStep name="print"> | ||
<Input class="DataObjects" type="DataSet">outPP</Input> | ||
<Input class="DataObjects" type="PointSet">myDO</Input> | ||
<Input class="DataObjects" type="HostorySet">TwistDO</Input> | ||
<Output class="OutStreams" type="Print">outPP</Output> | ||
<Output class="OutStreams" type="Plot">mySensorPlot</Output> | ||
</IOStep> | ||
</Steps> | ||
|
||
<Models> | ||
<PostProcessor name="mySPSL" subType="SparseSensing" verbosity="debug"> | ||
<Goal subType="reconstruction"> | ||
<features>X (m),Y (m),Temperature (K)</features> | ||
<target>Temperature (K)</target> | ||
<basis>SVD</basis> | ||
<nModes>4</nModes> | ||
<nSensors>4</nSensors> | ||
<optimizer>QR</optimizer> | ||
</Goal> | ||
</PostProcessor> | ||
</Models> | ||
|
||
<DataObjects> | ||
<PointSet name="myDO"> | ||
<Output>X (m),Temperature (K),Y (m)</Output> | ||
</PointSet> | ||
<HistorySet name="TwistDO"> | ||
<Input> Power (W), BCTemperature (K)</Input> | ||
<Output>X (m),Temperature (K),Y (m)</Output> | ||
<options> | ||
<pivotParameter>index</pivotParameter> | ||
</options> | ||
</HistorySet> | ||
<DataSet name="outPP"> | ||
<Input>InputPlaceHolder</Input> | ||
<Output>Temperature (K), X (m), Y (m)</Output> | ||
<Index var="sensor">X (m),Y (m),Temperature (K)</Index> | ||
</DataSet> | ||
</DataObjects> | ||
|
||
<OutStreams> | ||
<Print name="outPP"> | ||
<type>csv</type> | ||
<source>outPP</source> | ||
<what>output</what> | ||
</Print> | ||
<Plot name="mySensorPlot"> | ||
<plotSettings> | ||
<plot> | ||
<type>scatter</type> | ||
<x>myDO|Output|X (m)</x> | ||
<y>myDO|Output|Y (m)</y> | ||
<cmap>coolwarm</cmap> | ||
<colorMap>myDO|Output|Temperature (K)</colorMap> | ||
</plot> | ||
<plot> | ||
<type>scatter</type> | ||
<x>outPP|Output|X (m)</x> | ||
<y>outPP|Output|Y (m)</y> | ||
<c>magenta</c> | ||
<marker>*</marker> | ||
</plot> | ||
<xlabel>x</xlabel> | ||
<ylabel>y</ylabel> | ||
</plotSettings> | ||
<actions> | ||
<how>png</how> | ||
</actions> | ||
</Plot> | ||
</OutStreams> | ||
|
||
</Simulation> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
[Tests] | ||
[./SPSLOptiTwist] | ||
type = 'RavenFramework' | ||
input = 'testSPSLOptiTwist.xml' | ||
image = 'reconstructionOptiTwist/mySensorPlot_scatter-scatter.png' | ||
required_libraries = 'imageio' | ||
rel_err = 0.1 | ||
[./csv] | ||
type = OrderedCSV | ||
output = 'reconstructionOptiTwist/outPP.csv' | ||
rel_err = 0.001 | ||
[../] | ||
[../] | ||
[] |
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import numpy as np | ||
import matplotlib.pyplot as plt | ||
|
||
fig, ax = plt.subplots(figsize=(12,10)) | ||
|
||
xx = np.linspace(0,1,100) | ||
|
||
coeffs = [ | ||
(1, 0, 0.5), | ||
(0, 1, 1) | ||
] | ||
|
||
tot = np.zeros(len(xx)) | ||
for (A, B, k) in coeffs: | ||
c = 2 * np.pi / k | ||
yy = A*np.sin(c * xx) + B*np.cos(c * xx) | ||
ax.plot(xx, yy, ':', lw=5, label=f'({A},{B},{k})') | ||
tot += yy | ||
|
||
ax.plot(xx, tot, 'k-', lw=10, label='total') | ||
|
||
ax.legend() | ||
#plt.show() | ||
fig.savefig('fourier.png') |
Binary file not shown.
Oops, something went wrong.