mtewes / tenbilac

Neural network for inverse regression problems
1 stars 2 forks source link

log-problem with outdistribs plot #50

Closed mtewes closed 7 years ago

mtewes commented 7 years ago

Strange, never got this before. Investigating.

Traceback (most recent call last):
  File "run_3_learn.py", line 38, in <module>
    dirnames = megalut.learn.tenbilacrun.train(traincat, conflist, traindir)
  File "/users/mtewes/code/megalut-git/megalut/learn/tenbilacrun.py", line 78, in train
    ten.train(inputsdata, targetsdata, inputlabels, targetlabels)
  File "/users/mtewes/code/tenbilac-git/tenbilac/com.py", line 334, in train
    map(_trainworker, self.committee)
  File "/users/mtewes/code/tenbilac-git/tenbilac/com.py", line 519, in _trainworker
    trainobj.opt(**trainobj._trainkwargdict)
  File "/users/mtewes/code/tenbilac-git/tenbilac/train.py", line 505, in opt
    self.end()
  File "/users/mtewes/code/tenbilac-git/tenbilac/train.py", line 343, in end
    self.makeplots()
  File "/users/mtewes/code/tenbilac-git/tenbilac/train.py", line 281, in makeplots
    plot.outdistribs(self, filepath=self.plotpath("outdistribs", **kwargs))
  File "/users/mtewes/code/tenbilac-git/tenbilac/plot.py", line 350, in outdistribs
    ax.set_yscale('log')
  File "/usr/lib/python2.7/dist-packages/matplotlib/axes/_base.py", line 3096, in set_yscale
    self.autoscale_view(scalex=False)
  File "/usr/lib/python2.7/dist-packages/matplotlib/axes/_base.py", line 2197, in autoscale_view
    y0, y1 = ylocator.view_limits(y0, y1)
  File "/usr/lib/python2.7/dist-packages/matplotlib/ticker.py", line 1613, in view_limits
    "Data has no positive values, and therefore can not be "
ValueError: Data has no positive values, and therefore can not be log-scaled.
mtewes commented 7 years ago

Solved