Ignore:
Timestamp:
Jan 20, 2010 12:08:40 AM (10 years ago)
Author:
wehart
Message:

Adding diagnostic output.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • coopr.pyomo/trunk/coopr/pyomo/presolve/collect_linear_terms.py

    r2125 r2163  
    180180                if obj._data[ondx].expr is None:
    181181                    raise ValueError, "No expression has been defined for objective %s" % str(key)
    182                 t = obj._linterm[ondx] = self._Collect3(obj._data[ondx].expr)
     182                try:
     183                    t = obj._linterm[ondx] = self._Collect3(obj._data[ondx].expr)
     184                except Exception, e:
     185                    print "Error collecting linear terms for constraint %s (index %s)" % (str(key), str(ondx))
     186                    raise e
    183187                lt = len(t)
    184188                if lt > 0:
Note: See TracChangeset for help on using the changeset viewer.