Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(3)  |  Call(3)  |  Derive(0)  |  Import(0)

src/p/y/pylearn2-HEAD/pylearn2/optimization/test_batch_gradient_descent.py   pylearn2(Download)
            #is the objective function value at the parameters
            #chosen by the minimize method
            cur_obj = minimizer.obj(A,b,c)
            assert np.allclose(actual_obj, cur_obj)
 
            x.set_value(analytical_x)
            analytical_obj = minimizer.obj(A,b,c)
                print 'directional deriv at optimal: ',deriv
                x.set_value(optimal_x)
                print 'obj at optimal: ',minimizer.obj(A,b,c)