Skip to content
Snippets Groups Projects
Commit 4500e670 authored by Pospelov, Gennady's avatar Pospelov, Gennady
Browse files

Length of lines in Python scripts

parent 43287661
No related branches found
No related tags found
No related merge requests found
...@@ -69,7 +69,8 @@ def create_real_data(): ...@@ -69,7 +69,8 @@ def create_real_data():
real_data.setBinContent(i, noisy_amplitude) real_data.setBinContent(i, noisy_amplitude)
# uncomment line to save generated data on disk # uncomment line to save generated data on disk
#ba.IntensityDataIOFactory.writeIntensityData(real_data, 'refdata_fitcylinderprisms.int.gz') #ba.IntensityDataIOFactory.writeIntensityData(
# real_data, 'refdata_fitcylinderprisms.int.gz')
return real_data return real_data
......
...@@ -79,7 +79,7 @@ def run_fitting(): ...@@ -79,7 +79,7 @@ def run_fitting():
# Uncomment one of the line below to adjust minimizer settings # Uncomment one of the line below to adjust minimizer settings
# setting Minuit2 minimizer with Migrad algorithm, limiting number of iterations # setting Minuit2 minimizer with Migrad algorithm, limiting number of iterations
# Minimization will try to respect MaxFunctionCalls value and will stop around this value # Minimization will try to respect MaxFunctionCalls value
# fit_suite.setMinimizer("Minuit2", "Migrad", "MaxFunctionCalls=100") # fit_suite.setMinimizer("Minuit2", "Migrad", "MaxFunctionCalls=100")
# Setting two options at once. # Setting two options at once.
...@@ -92,14 +92,15 @@ def run_fitting(): ...@@ -92,14 +92,15 @@ def run_fitting():
# Setting Levenberg-Marquardt algorithm # Setting Levenberg-Marquardt algorithm
# fit_suite.setMinimizer("GSLLMA") # fit_suite.setMinimizer("GSLLMA")
# Setting Genetic algorithm # Setting Genetic algorithm.It requires all parameters
# It requires all parameters to be limited, so we recreate parameters with min and max defined # to be limited, so we recreate parameters with min and max defined
# fit_suite.fitParameters().clear() # fit_suite.fitParameters().clear()
# fit_suite.addFitParameter("*Cylinder/Height", 4.*nm).setLimited(3.0, 8.0) # fit_suite.addFitParameter("*Cylinder/Height", 4.*nm).setLimited(3.0, 8.0)
# fit_suite.addFitParameter("*Cylinder/Radius", 6.*nm).setLimited(3.0, 8.0) # fit_suite.addFitParameter("*Cylinder/Radius", 6.*nm).setLimited(3.0, 8.0)
# fit_suite.addFitParameter("*Prism3/Height", 4.*nm).setLimited(3.0, 8.0) # fit_suite.addFitParameter("*Prism3/Height", 4.*nm).setLimited(3.0, 8.0)
# fit_suite.addFitParameter("*Prism3/BaseEdge", 4.*nm).setLimited(3.0, 8.0) # fit_suite.addFitParameter("*Prism3/BaseEdge", 4.*nm).setLimited(3.0, 8.0)
# fit_suite.setMinimizer("Genetic", "Default", "MaxIterations=2;PopSize=200;RandomSeed=1") # fit_suite.setMinimizer("Genetic", "Default",
# "MaxIterations=2;PopSize=200;RandomSeed=1")
# running fit with default minimizer # running fit with default minimizer
fit_suite.runFit() fit_suite.runFit()
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment