Skip to content

Commit

Permalink
expose simulation gain file as parameter
Browse files Browse the repository at this point in the history
  • Loading branch information
maxnoe committed Mar 6, 2018
1 parent ae1044e commit cfa23fb
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/main/java/fact/gainservice/GainService.java
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,9 @@ public class GainService implements Service{
@Parameter(defaultValue = "classpath:/gains_20120503-20171103.fits.gz")
public URL gainFile = GainService.class.getResource("/gains_20120503-20171103.fits.gz");

@Parameter(defaultValue = "classpath:/mc_gain_ceres_12.csv")
public URL simulationGainFile = GainService.class.getResource("/mc_gain_ceres_12.csv");

TreeMap<ZonedDateTime, double[]> gains;
private double[] gainsSimulations = null;

Expand Down Expand Up @@ -99,7 +102,7 @@ public double[] getSimulationGains() {
private void loadGainsSimulations() {
double[] integralGains = new double[Constants.N_PIXELS];

SourceURL url = new SourceURL(GainService.class.getResource("/mc_gain_ceres_12.csv"));
SourceURL url = new SourceURL(simulationGainFile);
try {
CsvStream stream = new CsvStream(url, " ");
stream.setHeader(false);
Expand Down

0 comments on commit cfa23fb

Please sign in to comment.