Comparar commits
5 Commits
| Autor | SHA1 | Data | |
|---|---|---|---|
| a533669dd9 | |||
| c9935b52a3 | |||
| 1e2a634d5f | |||
| b755b78209 | |||
| 1ce0d70a25 |
@@ -35,3 +35,6 @@ test-tmp/
|
||||
blob-local-storage/
|
||||
src/seeds/nn/hash.txt
|
||||
src/seeds/pipeline/hash.txt
|
||||
|
||||
notes/
|
||||
src/worker
|
||||
|
||||
@@ -38,3 +38,6 @@ src/seeds/pipeline/hash.txt
|
||||
|
||||
# docs
|
||||
images/
|
||||
|
||||
notes/
|
||||
src/worker
|
||||
|
||||
+9
-1
@@ -4,6 +4,8 @@
|
||||
[](https://gitter.im/deepforge-dev/deepforge?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
|
||||
[](https://waffle.io/deepforge-dev/deepforge)
|
||||
|
||||
Using DeepForge? [Let us know what you think!](https://goo.gl/forms/2pDdCPXoUvkQhVzQ2)
|
||||
|
||||
# DeepForge
|
||||
DeepForge is an open-source visual development environment for deep learning providing end-to-end support for creating deep learning models. This is achieved through providing the ability to design **architectures**, create training **pipelines**, and then execute these pipelines over a cluster. Using a notebook-esque api, users can get real-time feedback about the status of any of their **executions** including compare them side-by-side in real-time.
|
||||
|
||||
@@ -46,7 +48,13 @@ Also, be sure to check out the other available features of the `deepforge` cli;
|
||||
- [Datamodel Developer Slides](https://docs.google.com/presentation/d/1hd3IyUlzW_TIPnzCnE-1pdz00Pw8WaIxYiOW_Hyog-M/edit#slide=id.p)
|
||||
|
||||
## Interested in contributing?
|
||||
Contributions are welcome! Either fork the project and submit some PR's or shoot me an email about getting more involved! If you have any questions, check out the [wiki](https://github.com/dfst/deepforge/wiki/) or drop me a line on the gitter!
|
||||
Contributions are welcome! There are a couple different ways to contribute to DeepForge:
|
||||
- Provide user feedback!
|
||||
- on the [documentation](http://deepforge.readthedocs.io)
|
||||
- on deepforge and its future development: https://goo.gl/forms/2pDdCPXoUvkQhVzQ2
|
||||
- Contribute to the project directly by submitting some PR's!
|
||||
|
||||
If you have any questions, check out the [wiki](https://github.com/dfst/deepforge/wiki/) or drop me a line on the gitter!
|
||||
|
||||
|
||||
Sponsored by [Digital Reasoning](http://www.digitalreasoning.com/)
|
||||
|
||||
@@ -26,11 +26,11 @@ The DeepForge server can be started with
|
||||
|
||||
.. code-block:: bash
|
||||
|
||||
docker run -d -v /home/irishninja/.deepforge/blob:/data/blob \
|
||||
docker run -d -v $HOME/.deepforge/blob:/data/blob \
|
||||
-p 8888:8888 -e MONGO_URI=mongodb://172.17.0.2:27017/deepforge \
|
||||
deepforge/server
|
||||
|
||||
where :code:`172.17.0.2` is the ip address of the mongo container and :code:`/home/irishninja/.deepforge/blob` is the path to use for binary DeepForge data on the host. Of course, if the mongo instance is locating at a different location, :code:`MONGO_URI` can be set to this address as well. Also, the first port (:code:`8888`) can be replaced with the desired port to expose on the host.
|
||||
where :code:`172.17.0.2` is the ip address of the mongo container and :code:`$HOME/.deepforge/blob` is the path to use for binary DeepForge data on the host. Of course, if the mongo instance is locating at a different location, :code:`MONGO_URI` can be set to this address as well. Also, the first port (:code:`8888`) can be replaced with the desired port to expose on the host.
|
||||
|
||||
Worker
|
||||
~~~~~~
|
||||
|
||||
+1
-1
@@ -17,7 +17,7 @@
|
||||
"watch-test": "nodemon --exec 'mocha --recursive test'",
|
||||
"build-nn": "node ./utils/nn-parser.js"
|
||||
},
|
||||
"version": "1.3.0",
|
||||
"version": "1.4.0",
|
||||
"dependencies": {
|
||||
"commander": "^2.9.0",
|
||||
"dotenv": "^2.0.0",
|
||||
|
||||
@@ -5,16 +5,24 @@ define([
|
||||
'ace/ace',
|
||||
'underscore',
|
||||
'./completer',
|
||||
'js/Utils/ComponentSettings',
|
||||
'jquery-contextMenu',
|
||||
'css!./styles/TextEditorWidget.css'
|
||||
], function (
|
||||
ace,
|
||||
_,
|
||||
Completer
|
||||
Completer,
|
||||
ComponentSettings
|
||||
) {
|
||||
'use strict';
|
||||
|
||||
var TextEditorWidget,
|
||||
WIDGET_CLASS = 'text-editor';
|
||||
WIDGET_CLASS = 'text-editor',
|
||||
DEFAULT_SETTINGS = {
|
||||
keybindings: 'default',
|
||||
theme: 'solarized_dark',
|
||||
fontSize: 12
|
||||
};
|
||||
|
||||
TextEditorWidget = function (logger, container) {
|
||||
this._logger = logger.fork('Widget');
|
||||
@@ -27,9 +35,13 @@ define([
|
||||
|
||||
this.readOnly = this.readOnly || false;
|
||||
this.editor = ace.edit(this.$editor[0]);
|
||||
this._initialize();
|
||||
|
||||
// Get the config from component settings for themes
|
||||
this.editor.getSession().setOptions(this.getSessionOptions());
|
||||
var handler = this.editorSettings.keybindings;
|
||||
this.editor.setKeyboardHandler(handler === 'default' ?
|
||||
null : 'ace/keyboard/' + handler);
|
||||
this.addExtensions();
|
||||
this.editor.$blockScrolling = Infinity;
|
||||
this.DELAY = 750;
|
||||
@@ -47,7 +59,6 @@ define([
|
||||
this.setReadOnly(this.readOnly);
|
||||
this.currentHeader = '';
|
||||
this.activeNode = null;
|
||||
this._initialize();
|
||||
|
||||
this._logger.debug('ctor finished');
|
||||
};
|
||||
@@ -68,7 +79,8 @@ define([
|
||||
return {
|
||||
enableBasicAutocompletion: true,
|
||||
enableLiveAutocompletion: true,
|
||||
fontSize: '12pt'
|
||||
theme: 'ace/theme/' + this.editorSettings.theme,
|
||||
fontSize: this.editorSettings.fontSize + 'pt'
|
||||
};
|
||||
};
|
||||
|
||||
@@ -83,6 +95,124 @@ define([
|
||||
TextEditorWidget.prototype._initialize = function () {
|
||||
// set widget class
|
||||
this._el.addClass(WIDGET_CLASS);
|
||||
|
||||
// Add context menu
|
||||
$.contextMenu('destroy', '.' + WIDGET_CLASS);
|
||||
$.contextMenu({
|
||||
selector: '.' + WIDGET_CLASS,
|
||||
build: $trigger => {
|
||||
return {
|
||||
items: this.getMenuItemsFor($trigger)
|
||||
};
|
||||
}
|
||||
});
|
||||
|
||||
// Create the editor settings
|
||||
this.editorSettings = _.extend({}, DEFAULT_SETTINGS),
|
||||
ComponentSettings.resolveWithWebGMEGlobal(
|
||||
this.editorSettings,
|
||||
this.getComponentId()
|
||||
);
|
||||
};
|
||||
|
||||
TextEditorWidget.prototype.getComponentId = function () {
|
||||
return 'TextEditor';
|
||||
};
|
||||
|
||||
TextEditorWidget.prototype.getMenuItemsFor = function () {
|
||||
var fontSizes = [8, 10, 11, 12, 14],
|
||||
themes = [
|
||||
'Solarized Light',
|
||||
'Solarized Dark',
|
||||
'Twilight',
|
||||
'Tomorrow Night',
|
||||
'Eclipse',
|
||||
'Monokai'
|
||||
],
|
||||
keybindings = [
|
||||
'default',
|
||||
'vim',
|
||||
'emacs'
|
||||
],
|
||||
menuItems = {
|
||||
setKeybindings: {
|
||||
name: 'Keybindings...',
|
||||
items: {}
|
||||
},
|
||||
setFontSize: {
|
||||
name: 'Font Size...',
|
||||
items: {}
|
||||
},
|
||||
setTheme: {
|
||||
name: 'Theme...',
|
||||
items: {}
|
||||
}
|
||||
};
|
||||
|
||||
fontSizes.forEach(fontSize => {
|
||||
var name = fontSize + ' pt',
|
||||
isSet = fontSize === this.editorSettings.fontSize;
|
||||
|
||||
if (isSet) {
|
||||
name = '<span style="font-weight: bold">' + name + '</span>';
|
||||
}
|
||||
|
||||
menuItems.setFontSize.items['font' + fontSize] = {
|
||||
name: name,
|
||||
isHtmlName: isSet,
|
||||
callback: () => {
|
||||
this.editorSettings.fontSize = fontSize;
|
||||
this.editor.setOptions(this.getEditorOptions());
|
||||
this.onUpdateEditorSettings();
|
||||
}
|
||||
};
|
||||
});
|
||||
|
||||
themes.forEach(name => {
|
||||
var theme = name.toLowerCase().replace(/ /g, '_'),
|
||||
isSet = theme === this.editorSettings.theme;
|
||||
|
||||
if (isSet) {
|
||||
name = '<span style="font-weight: bold">' + name + '</span>';
|
||||
}
|
||||
|
||||
menuItems.setTheme.items[theme] = {
|
||||
name: name,
|
||||
isHtmlName: isSet,
|
||||
callback: () => {
|
||||
this.editorSettings.theme = theme;
|
||||
this.editor.setOptions(this.getEditorOptions());
|
||||
this.onUpdateEditorSettings();
|
||||
}
|
||||
};
|
||||
});
|
||||
|
||||
keybindings.forEach(name => {
|
||||
var handler = name.toLowerCase().replace(/ /g, '_'),
|
||||
isSet = handler === this.editorSettings.keybindings;
|
||||
|
||||
if (isSet) {
|
||||
name = '<span style="font-weight: bold">' + name + '</span>';
|
||||
}
|
||||
|
||||
menuItems.setKeybindings.items[handler] = {
|
||||
name: name,
|
||||
isHtmlName: isSet,
|
||||
callback: () => {
|
||||
this.editorSettings.keybindings = handler;
|
||||
this.editor.setKeyboardHandler(handler === 'default' ?
|
||||
null : 'ace/keyboard/' + handler);
|
||||
this.onUpdateEditorSettings();
|
||||
}
|
||||
};
|
||||
});
|
||||
|
||||
return menuItems;
|
||||
};
|
||||
|
||||
TextEditorWidget.prototype.onUpdateEditorSettings = function () {
|
||||
ComponentSettings.overwriteComponentSettings(this.getComponentId(), this.editorSettings,
|
||||
err => err && this._logger.error(`Could not save editor settings: ${err}`));
|
||||
};
|
||||
|
||||
TextEditorWidget.prototype.onWidgetContainerResize = function () {
|
||||
@@ -147,6 +277,7 @@ define([
|
||||
/* * * * * * * * Visualizer life cycle callbacks * * * * * * * */
|
||||
TextEditorWidget.prototype.destroy = function () {
|
||||
this.editor.destroy();
|
||||
$.contextMenu('destroy', '.' + WIDGET_CLASS);
|
||||
};
|
||||
|
||||
TextEditorWidget.prototype.onActivate = function () {
|
||||
|
||||
Referência em uma Nova Issue
Bloquear um usuário