
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
[![NPM version][npm-image]][npm-url] [![build status][travis-image]][travis-url] [![David deps][david-image]][david-url] [![npm download][download-image]][download-url]
$ npm install ml-xgboost
import IrisDataset from 'ml-dataset-iris';
require('ml-xgboost').then(XGBoost => {
var booster = new XGBoost({
booster: 'gbtree',
objective: 'multi:softmax',
max_depth: 5,
eta: 0.1,
min_child_weight: 1,
subsample: 0.5,
colsample_bytree: 1,
silent: 1,
iterations: 200
});
var trainingSet = IrisDataset.getNumbers();
var predictions = IrisDataset.getClasses().map(
(elem) => IrisDataset.getDistinctClasses().indexOf(elem)
);
booster.train(dataset, trueLabels);
var predictDataset = /* something to predict */
var predictions = booster.predict(predictDataset);
// don't forget to free your model
booster.free()
// you can save your model in this way
var model = JSON.stringify(booster); // string
// or
var model = booster.toJSON(); // object
// and load it
var anotherBooster = XGBoost.load(model); // model is an object, not a string
});
emcc and em++.git clone --recursive https://github.com/mljs/xgboostnpm run build or make at the root directory.dmlc-core/include/dmlc/base.h line 45 here
rabit/include/dmlc/base.h line 45 here
#if (!defined(DMLC_LOG_STACK_TRACE) && defined(__GNUC__) && !defined(__MINGW32__))
#define DMLC_LOG_STACK_TRACE 1
#undef DMLC_LOG_STACK_TRACE
#endif
Note: this is to avoid compilation issues with the execinfo.h library that is not needed in the JS library
in case that you get the following error:
./xgboost/include/xgboost/c_api.h:29:9: error: unknown type name 'uint64_t'
just add this import at the beginning of this file after the first define:
#include <stdint.h>
© Contributors, 2016. Licensed under an Apache-2 license.
FAQs
[![NPM version][npm-image]][npm-url] [![build status][travis-image]][travis-url] [![David deps][david-image]][david-url] [![npm download][download-image]][download-url]
The npm package ml-xgboost receives a total of 395 weekly downloads. As such, ml-xgboost popularity was classified as not popular.
We found that ml-xgboost demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 5 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.