clicumu / doepipeline

A python package for optimizing processing pipelines using statistical design of experiments (DoE).
MIT License
23 stars 2 forks source link

rounded ints passed as arguments, floats used for internal calculations #3

Closed danisven closed 6 years ago

danisven commented 8 years ago

Changes made in this commit introduces a discrepancy between what arguments are actually used for an experiment, and what arguments doepipeline thinks were used. All factor values are rounded and turned into ints before substituting them into the template script. This because HaplotypeCaller (and probably more softwares) take int arguments and cannot handle floats.

druvus commented 8 years ago

I suggest the approach mentioned in #5

RickardSjogren commented 8 years ago

This introduces an error. Quantitative variables should not be rounded of.

The need for this however highlights another error. There is currently no proper support for qualitative or ordinal factors which ought to be fixed, discussed in #5.

danisven commented 8 years ago

This has been changed to only round the factor values that belong to the class OrdinalFactor, factor values of any other class are not rounded.

There is no support for dealing with ordinal factors in scipy.optimize from what I can tell. All the minimize functions deal with the factors as continuous. Without including another solver we will not be able to deal with ordinal factors the correct way.

Solving functions where parameters are ordinal is part of Integer programming (IP). There are open source solvers that can solve integer linear programming (ILP) and mixed integer programming (MIP) problems, such as GLPK with python bindings. However I cannot find any integer quadratic programming (IQP) or mixed integer quadratic programming (MIQP) solvers that are open source, but instead there are a number or proprietary softwares (some with free academic licenses).

RickardSjogren commented 6 years ago

I consider this solved by the current way of simply rounding ordinal factors after optimization.