config = tf.ConfigProto( device_count = {'GPU': 0 , 'CPU': 30} )
sess = tf.Session(config=config)
keras.backend.set_session( sess)
model.fit(x_train, y_train, epochs=epochs, validation_ data=(x_test, y_test))
export | |
const restartRunAll = 'notebook:restart-run-all'; |
help(server.launch)
Help on function launch in module quiver_engine.server:
launch(model, temp_folder='./tmp', input_folder='./', port=5000, html_base_dir=None)
optimizer = tf.train.AdamOptimizer(1e-3) train_op = optimizer.minimize(cnn.loss, global_step=global_step)
optimizer = tf.train.AdamOptimizer(1e-3)
grads_and_vars = optimizer.compute_gradients(cnn.loss)
train_op = optimizer.apply_gradients(grads_and_vars, global_step=global_step)
void Main()
{
Thread thread = null;
Task t = Task.Run(() =>
{
//Capture the thread
thread = Thread.CurrentThread;
//Simulate work (usually from 3rd party code)
Thread.Sleep(1000);
//If you comment out thread.Abort(), then this will be displayed
Console.WriteLine("Task finished!");
});
//This is needed in the example to avoid thread being still NULL
Thread.Sleep(10);
//Cancel the task by aborting the thread
thread.Abort();
}
Mat i1 = new Mat("D:/New folder/images/Fit01.jpg", LoadImageType.Color);
Mat i2 = new Mat("D:/New folder/images/Fit02.jpg", LoadImageType.Color);
Mat i3 = new Mat("D:/New folder/images/Fit02.jpg", LoadImageType.Color);
using (VectorOfMat vmsrc = new VectorOfMat(i1, i2, i3))
{
Image<Bgr, byte> res = new Image<Bgr, byte>(1000, 750);
Mat result = new Mat();
Stitcher stitcher = new Stitcher(false);
stitcher.Stitch(vmsrc, result);
ImageViewer.Show(result);
}