veles.znicz NN engine focuses on performance and flexibility. It has little hard-coded entities and enables training of all the widely recognized topologies, such as fully connected nets, convolutional nets, reccurent nets etc.
In-depth introspection and rich debugging facilities helps to develop nets quickly with predictable result.
All backends have the same interface and yield the same calculation results or accuracy, with single or double precision.
ZeroMQ-based star topology of distributed operation handles up to 100 nodes, depending on the task. Optionally, some compression can be applied. The state of things is sent to the Web Status Server.
The whole thing is fault tolerant, the death of a node does not cause the master stop. You can add new nodes dynamically, at any time, with any backends.
Snapshotting feature allows recovering from any disaster, restart the training in a different mode and with a different backend.
Upload your workflows to Forge. Access others' work. See what Veles is capable of.
import veles
launcher=veles("veles/znicz/samples/MnistSimple/mnist.py", stealth=True, backend="ocl", matplotlib_backend="WebAgg")
launcher.pause()
%matplotlib inline
launcher.workflow.units
plotter = launcher.workflow["Validation matrix"]
plotter.set_matplotlib(plotter.import_matplotlib())
plotter.redraw()
launcher.workflow[4]
launcher.workflow[4].weights.map_read()
launcher.workflow[4].weights.mem
launcher=veles("veles/znicz/samples/YaleFaces/yale_faces.py", "-", "root.yalefaces.decision.max_epochs=20;root.common.disable.publishing=True", stealth=True, backend="ocl", matplotlib_backend="WebAgg")
from veles.znicz.labels_printer import LabelsPrinter
fwd = launcher.workflow.extract_forward_workflow(
loader_name="interactive_image", loader_config={},
result_unit_factory=LabelsPrinter, cyclic=True)
launcher.boot()
feed("http://cont.ws/uploads/posts/78168.jpg")
Receive automatic reports when the training ends. The supported formats include Atlassian Confluence; PDF, Latex and HTML backends are not yet implemented - but soon will be.
Veles includes "bboxer", a collaborative tool for image dataset markup.
Requires no data preprocessingINFO:MnistLoader:Loading from original MNIST files... INFO:MnistLoader:Minibatch size is set to 88 See the number of samples in each setINFO:MnistLoader:Samples number: test: 0, validation: 10000, train: 60000 DEBUG:MnistLoader:Shuffling, remaining limit is 4294967294 DEBUG:MnistLoader:Shuffled train set Various data normalization algorithmsINFO:MnistLoader:Normalizing to linear... DEBUG:MnistLoader:Data range: (0.000000, 255.000000), DEBUG:MnistLoader:Normalized data range: (-1.000000, 1.000000), The number of classes in the raw dataINFO:MnistLoader:There are 10 unique labels INFO:MnistLoader:train label cardinalities: min: 5421 ("5"), max: 6742 ("1"), avg: 6000, σ: 322 (5%) DEBUG:MnistLoader:Detailed train label stats: +-------+-------------+------+---------------------------+ | Label | Cardinality | % | Histogram | +-------+-------------+------+---------------------------+ | 0 | 5923 | 9.9 | ********************* | | 1 | 6742 | 11.2 | ************************* | | 2 | 5958 | 9.9 | ********************** | | 3 | 6131 | 10.2 | ********************** | | 4 | 5842 | 9.7 | ********************* | | 5 | 5421 | 9.0 | ******************** | | 6 | 5918 | 9.9 | ********************* | | 7 | 6265 | 10.4 | *********************** | | 8 | 5851 | 9.8 | ********************* | | 9 | 5949 | 9.9 | ********************** | +-------+-------------+------+---------------------------+ Calculates the cardinality standard deviation to reflect the balanceINFO:MnistLoader:validation label cardinalities: min: 892 ("5"), max: 1135 ("1"), avg: 1000, σ: 59 (5%) DEBUG:MnistLoader:Detailed validation label stats: +-------+-------------+------+---------------------------+ | Label | Cardinality | % | Histogram | +-------+-------------+------+---------------------------+ | 0 | 980 | 9.8 | ********************* | | 1 | 1135 | 11.3 | ************************* | | 2 | 1032 | 10.3 | ********************** | | 3 | 1010 | 10.1 | ********************** | | 4 | 982 | 9.8 | ********************* | | 5 | 892 | 8.9 | ******************* | | 6 | 958 | 9.6 | ********************* | | 7 | 1028 | 10.3 | ********************** | | 8 | 974 | 9.7 | ********************* | | 9 | 1009 | 10.1 | ********************** | +-------+-------------+------+---------------------------+ Does a simple test on mutual set balanceINFO:MnistLoader:OK: train and validation labels have the same distributions (Χ-square test's p-value is 1.000) INFO:MnistLoader:Will try to store the entire dataset on the device DEBUG:MnistLoader:Used the cached fullbatch_loader for engine "ocl"
Veles is bundled with Mastodon, a subproject which integrates it with any Java application. Mastodon includes a simple load balancer between Java nodes and Veles slaves.
Extract features in Hadoop and classify objects in Veles. Analyze data in Veles and pass the results next through the pipeline.
Machine learning model execution goes in a workflow, which consists of units and child workflows. Units represent logically independent and integral algorithm parts. E.g. single network layer is a unit; the gradient descent step is another unit.
Veles uses a typical data driven approach, where control flow is ruled by data processing through control flow links between units.
Such architecture allows easily manageable data parallel and model parallel execution of models.
Veles is cluster and Docker friendly. Deploy the exported tarball, initialize the pyenv environment and you are ready to go - with just 2 simple commands.
REST API allows to use the trained model in a production environment at once.
Manhole feature allows to execute an interactive IPython session in the running process context at any time.
Live reload feature allows changing the Python code without restarting the process.
And many, many more...
If I have seen further it is by standing on the shoulders of giants.
Send pull requests on GitHub, they will be automatically converted into Gerrit patchsets. Watch how nightly tests run in Jenkins.
There is plenty of work to do: port to Windows and Mac OS X, add CuDNN support, extend reporting options, improve the distributed operation and many, many more.