StackGenVis: Alignment of Data, Algorithms, and Models for Stacking Ensemble Learning Using Performance Metrics
https://doi.org/10.1109/TVCG.2020.3030352
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
39 lines
812 B
39 lines
812 B
'use strict';
|
|
|
|
var debug = require('../debug');
|
|
|
|
/**
|
|
* Load views onto the given collections.
|
|
*
|
|
* ```json
|
|
* {"verb": {"plugins": {"eslint": {"name": "gulp-eslint"}}}}
|
|
* ```
|
|
* @name plugins
|
|
* @api public
|
|
*/
|
|
|
|
module.exports = function(app) {
|
|
return function(collections, key, config, next) {
|
|
debug.field(key, collections);
|
|
|
|
if (key === 'templates') {
|
|
collections = config.views = config.templates;
|
|
delete config.templates;
|
|
}
|
|
|
|
if (typeof app.create !== 'function') {
|
|
next(new Error('expected app.create to be a function'));
|
|
return;
|
|
}
|
|
|
|
for (var prop in collections) {
|
|
if (typeof this[prop] !== 'function') {
|
|
app.create(prop);
|
|
}
|
|
|
|
debug('loading collection "%s"', prop);
|
|
this[prop](collections[prop]);
|
|
}
|
|
next();
|
|
};
|
|
};
|
|
|