Skip to content

Commit

Permalink
fixed conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
StrikerRUS committed May 16, 2019
2 parents 4a77a8b + c9d681a commit 98b592e
Show file tree
Hide file tree
Showing 53 changed files with 74 additions and 1,801 deletions.
6 changes: 6 additions & 0 deletions .ci/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
Helper Scripts for CI
=====================

This folder contains scripts which are run on CI services.

Dockerfile used on CI service is maintained in a separate [GitHub repository](https://github.com/guolinke/lightgbm-ci-docker) and can be pulled from [Docker Hub](https://hub.docker.com/r/lightgbm/vsts-agent).
79 changes: 0 additions & 79 deletions .ci/dockers/ubuntu-14.04/Dockerfile

This file was deleted.

3 changes: 3 additions & 0 deletions .ci/setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ if [[ $OS_NAME == "macos" ]]; then
if [[ $TASK == "mpi" ]]; then
brew install open-mpi
fi
if [[ $AZURE == "true" ]] && [[ $TASK == "sdist" ]]; then
brew install https://raw.githubusercontent.com/Homebrew/homebrew-core/f3544543a3115023fc7ca962c21d14b443f419d0/Formula/swig.rb # swig 3.0.12
fi
wget -q -O conda.sh https://repo.continuum.io/miniconda/Miniconda${PYTHON_VERSION:0:1}-latest-MacOSX-x86_64.sh
else # Linux
if [[ $AZURE == "true" ]] && [[ $COMPILER == "clang" ]]; then
Expand Down
26 changes: 13 additions & 13 deletions .ci/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,6 @@ else
CMAKE_OPTS=()
fi

if [[ $AZURE == "true" ]] && [[ $OS_NAME == "linux" ]] && [[ $TASK == "swig" ]]; then
mkdir $BUILD_DIRECTORY/build && cd $BUILD_DIRECTORY/build
cmake -DUSE_SWIG=ON "${CMAKE_OPTS[@]}" ..
make -j4 || exit -1
if [[ $COMPILER == "gcc" ]]; then
objdump -T $BUILD_DIRECTORY/lib_lightgbm.so > $BUILD_DIRECTORY/objdump.log || exit -1
objdump -T $BUILD_DIRECTORY/lib_lightgbm_swig.so >> $BUILD_DIRECTORY/objdump.log || exit -1
python $BUILD_DIRECTORY/helpers/check_dynamic_dependencies.py $BUILD_DIRECTORY/objdump.log || exit -1
fi
cp $BUILD_DIRECTORY/build/lightgbmlib.jar $BUILD_ARTIFACTSTAGINGDIRECTORY/lightgbmlib.jar
exit 0
fi

conda create -q -y -n $CONDA_ENV python=$PYTHON_VERSION
source activate $CONDA_ENV

Expand Down Expand Up @@ -91,6 +78,19 @@ if [[ $TASK == "sdist" ]]; then
pip install --user $BUILD_DIRECTORY/python-package/dist/lightgbm-$LGB_VER.tar.gz -v || exit -1
if [[ $AZURE == "true" ]]; then
cp $BUILD_DIRECTORY/python-package/dist/lightgbm-$LGB_VER.tar.gz $BUILD_ARTIFACTSTAGINGDIRECTORY
mkdir $BUILD_DIRECTORY/build && cd $BUILD_DIRECTORY/build
if [[ $OS_NAME == "macos" ]]; then
cmake -DUSE_SWIG=ON -DAPPLE_OUTPUT_DYLIB=ON "${CMAKE_OPTS[@]}" ..
else
cmake -DUSE_SWIG=ON "${CMAKE_OPTS[@]}" ..
fi
make -j4 || exit -1
if [[ $OS_NAME == "linux" ]] && [[ $COMPILER == "gcc" ]]; then
objdump -T $BUILD_DIRECTORY/lib_lightgbm.so > $BUILD_DIRECTORY/objdump.log || exit -1
objdump -T $BUILD_DIRECTORY/lib_lightgbm_swig.so >> $BUILD_DIRECTORY/objdump.log || exit -1
python $BUILD_DIRECTORY/helpers/check_dynamic_dependencies.py $BUILD_DIRECTORY/objdump.log || exit -1
fi
cp $BUILD_DIRECTORY/build/lightgbmlib.jar $BUILD_ARTIFACTSTAGINGDIRECTORY/lightgbmlib_$OS_NAME.jar
fi
pytest $BUILD_DIRECTORY/tests/python_package_test || exit -1
exit 0
Expand Down
9 changes: 9 additions & 0 deletions .ci/test_windows.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,15 @@ elseif ($env:TASK -eq "sdist") {
cd $env:BUILD_SOURCESDIRECTORY/python-package
python setup.py sdist --formats gztar ; Check-Output $?
cd dist; pip install @(Get-ChildItem *.gz) -v ; Check-Output $?

$env:JAVA_HOME = $env:JAVA_HOME_8_X64 # there is pre-installed Zulu OpenJDK-8 somewhere
Invoke-WebRequest -Uri "https://sourceforge.net/projects/swig/files/swigwin/swigwin-3.0.12/swigwin-3.0.12.zip/download" -OutFile $env:BUILD_SOURCESDIRECTORY/swig/swigwin.zip -UserAgent "NativeHost"
Add-Type -AssemblyName System.IO.Compression.FileSystem
[System.IO.Compression.ZipFile]::ExtractToDirectory("$env:BUILD_SOURCESDIRECTORY/swig/swigwin.zip", "$env:BUILD_SOURCESDIRECTORY/swig")
$env:PATH += ";$env:BUILD_SOURCESDIRECTORY/swig/swigwin-3.0.12"
mkdir $env:BUILD_SOURCESDIRECTORY/build; cd $env:BUILD_SOURCESDIRECTORY/build
cmake -A x64 -DUSE_SWIG=ON .. ; cmake --build . --target ALL_BUILD --config Release ; Check-Output $?
cp $env:BUILD_SOURCESDIRECTORY/build/lightgbmlib.jar $env:BUILD_ARTIFACTSTAGINGDIRECTORY/lightgbmlib_win.jar
}
elseif ($env:TASK -eq "bdist") {
cd $env:BUILD_SOURCESDIRECTORY/python-package
Expand Down
2 changes: 2 additions & 0 deletions R-package/R/lgb.prepare.R
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@
#' # $ Petal.Width : num 0.2 0.2 0.2 0.2 0.2 0.4 0.3 0.2 0.2 0.1 ...
#' # $ Species : num 1 1 1 1 1 1 1 1 1 1 ...
#'
#' \dontrun{
#' # When lightgbm package is installed, and you do not want to load it
#' # You can still use the function!
#' lgb.unloader()
Expand All @@ -36,6 +37,7 @@
#' # $ Petal.Length: num 1.4 1.4 1.3 1.5 1.4 1.7 1.4 1.5 1.4 1.5 ...
#' # $ Petal.Width : num 0.2 0.2 0.2 0.2 0.2 0.4 0.3 0.2 0.2 0.1 ...
#' # $ Species : num 1 1 1 1 1 1 1 1 1 1 ...
#' }
#'
#' @export
lgb.prepare <- function(data) {
Expand Down
2 changes: 2 additions & 0 deletions R-package/R/lgb.prepare2.R
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
#' # $ Petal.Width : num 0.2 0.2 0.2 0.2 0.2 0.4 0.3 0.2 0.2 0.1 ...
#' # $ Species : int 1 1 1 1 1 1 1 1 1 1 ...
#'
#' \dontrun{
#' # When lightgbm package is installed, and you do not want to load it
#' # You can still use the function!
#' lgb.unloader()
Expand All @@ -37,6 +38,7 @@
#' # $ Petal.Length: num 1.4 1.4 1.3 1.5 1.4 1.7 1.4 1.5 1.4 1.5 ...
#' # $ Petal.Width : num 0.2 0.2 0.2 0.2 0.2 0.4 0.3 0.2 0.2 0.1 ...
#' # $ Species : int 1 1 1 1 1 1 1 1 1 1 ...
#' }
#'
#' @export
lgb.prepare2 <- function(data) {
Expand Down
3 changes: 3 additions & 0 deletions R-package/R/lgb.unloader.R
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,15 @@
#' min_data = 1,
#' learning_rate = 1,
#' early_stopping_rounds = 10)
#'
#' \dontrun{
#' lgb.unloader(restore = FALSE, wipe = FALSE, envir = .GlobalEnv)
#' rm(model, dtrain, dtest) # Not needed if wipe = TRUE
#' gc() # Not needed if wipe = TRUE
#'
#' library(lightgbm)
#' # Do whatever you want again with LightGBM without object clashing
#' }
#'
#' @export
lgb.unloader <- function(restore = TRUE, wipe = FALSE, envir = .GlobalEnv) {
Expand Down
41 changes: 2 additions & 39 deletions R-package/_pkgdown.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ site:
title: LightGBM, Light Gradient Boosting Machine

reference:
- title: Dataset
- title: Datasets
desc: Datasets included with the R package
contents:
- '`agaricus.test`'
Expand Down Expand Up @@ -52,7 +52,7 @@ reference:
- '`lgb.cv`'
- '`lgb.train`'
- title: Saving / Loading Models
desc: Save and Load LightGBM models
desc: Save and load LightGBM models
contents:
- '`lgb.dump`'
- '`lgb.load`'
Expand Down Expand Up @@ -82,43 +82,6 @@ navbar:
href: index.html
- text: Reference
href: reference/index.html
- text: Vignettes
menu:
- text: Basic Walkthrough
href: articles/basic_walkthrough.html
- text: Boosting from existing prediction
href: articles/boost_from_prediction.html
- text: Categorical Feature Preparation
href: articles/categorical_features_prepare.html
- text: Categorical Feature Preparation with Rule
href: articles/categorical_features_rules.html
- text: Cross Validation
href: articles/cross_validation.html
- text: Early Stop in training
href: articles/early_stopping.html
- text: Efficiency for Many Model Trainings
href: articles/efficient_many_training.html
- text: Leaf (in)Stability example
href: articles/leaf_stability.html
- text: Multiclass training/prediction
href: articles/multiclass.html
- text: Weight-Parameter adjustment relationship
href: articles/weight_param.html
right:
- icon: fa-github fa-lg
href: https://github.com/Microsoft/LightGBM

articles:
- title: Vignettes
desc: ~
contents:
- '`basic_walkthrough`'
- '`boost_from_prediction`'
- '`categorical_features_prepare`'
- '`categorical_features_rules`'
- '`cross_validation`'
- '`early_stopping`'
- '`efficient_many_training`'
- '`leaf_stability`'
- '`multiclass`'
- '`weight_param`'
31 changes: 0 additions & 31 deletions R-package/man/agaricus.test.Rd

This file was deleted.

31 changes: 0 additions & 31 deletions R-package/man/agaricus.train.Rd

This file was deleted.

25 changes: 0 additions & 25 deletions R-package/man/bank.Rd

This file was deleted.

34 changes: 0 additions & 34 deletions R-package/man/dim.Rd

This file was deleted.

Loading

0 comments on commit 98b592e

Please sign in to comment.