<commit_before>language: cpp

# Cache Ubuntu apt packages.
cache: apt

compiler:
  - gcc
# Disable clang build: doesn't seem to work on Linux.
# (@jeffdonahue: Travis buildbot's failure behavior is similar to what I see
# building on Linux.)
#   - clang

before_install:
  - echo $LANG
  - echo $LC_ALL
  - sudo apt-get -y update
  - sudo apt-get -y install wget git curl python-dev python-numpy libprotobuf-dev libleveldb-dev libsnappy-dev libopencv-dev libboost-all-dev libhdf5-serial-dev protobuf-compiler libatlas-dev libatlas-base-dev bc

install:
  # CMake 2.8.12
<<<<<<< HEAD
  - wget http://www.cmake.org/files/v2.8/cmake-2.8.12.tar.gz -O /tmp/cmake.tar.gz && tar -C /tmp -xvf /tmp/cmake.tar.gz && rm /tmp/cmake.tar.gz
  - cd /tmp/cmake-2.8.12 && ./bootstrap --prefix=/usr && make -j4 &&  sudo make install -j4 &&  cd - #&& rm -r /tmp/cmake-2.8.12
=======
  - wget http://www.cmake.org/files/v2.8/cmake-2.8.12.2-Linux-i386.tar.gz -O /tmp/cmake.tar.gz && tar -C /tmp -xvf /tmp/cmake.tar.gz && rm /tmp/cmake.tar.gz 
  - cd /tmp/cmake-2.8.12.2-Linux-i386 && sudo cp * /usr/ -r && cd - && rm -r /tmp/cmake-2.8.12.2-Linux-i386
>>>>>>> cmake from binaries
    #
  - wget https://google-glog.googlecode.com/files/glog-0.3.3.tar.gz -O /tmp/glog-0.3.3.tar.gz && tar -C /tmp -xzvf /tmp/glog-0.3.3.tar.gz && rm /tmp/glog-0.3.3.tar.gz
  - cd /tmp/glog-0.3.3 && ./configure && make -j4 && sudo make install -j4 && cd -
  - wget https://github.com/schuhschuh/gflags/archive/master.zip -O /tmp/gflags-master.zip && pushd /tmp/ && unzip gflags-master.zip && cd gflags-master && mkdir build && cd build && export CXXFLAGS="-fPIC" && cmake .. && make VERBOSE=1 && sudo make install && popd
  - curl http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1204/x86_64/cuda-repo-ubuntu1204_6.0-37_amd64.deb -o /tmp/cuda_install.deb && sudo dpkg -i /tmp/cuda_install.deb && rm /tmp/cuda_install.deb
  - sudo apt-get -y update
  # Install the minimal CUDA subpackages required to test Caffe build.
  # For a full CUDA installation, add 'cuda' to the list of packages.
  - sudo apt-get -y install cuda-core-6-0 cuda-extra-libs-6-0
  # Create CUDA symlink at /usr/local/cuda
  # (This would normally be created by the CUDA installer, but we create it
  # manually since we did a partial installation.)
  - sudo ln -s /usr/local/cuda-6.0 /usr/local/cuda
  - curl https://gitorious.org/mdb/mdb/archive/7f038d0f15bec57b4c07aa3f31cd5564c88a1897.tar.gz -o /tmp/mdb.tar.gz && tar -C /tmp -xzvf /tmp/mdb.tar.gz && rm /tmp/mdb.tar.gz
  - cd /tmp/mdb-mdb/libraries/liblmdb/ && make -j4 && sudo make install -j4 && cd -

before_script:
  - mv Makefile.config.example Makefile.config
  - export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib
  - export NUM_THREADS=4

script:
  # CMake build.
  - mkdir build
  - cd build
  - cmake -DBUILD_PYTHON=ON -DBUILD_EXAMPLES=ON -DCMAKE_BUILD_TYPE=Release ..
  - make --keep-going --jobs=$NUM_THREADS
  - make clean
  - cd ..
  - rm -r build

  # CPU-GPU: build only.
  - export CPU_ONLY=0
  - make --keep-going --jobs=$NUM_THREADS all
  - make clean
  # CPU-only: comprehensive.
  - export CPU_ONLY=1
  - make --keep-going --jobs=$NUM_THREADS all test warn lint
  - make runtest
  - make --jobs=$NUM_THREADS all
  - make --jobs=$NUM_THREADS test<commit_msg>enable both GPU and CPU builds + testing in travis<commit_after>language: cpp

# Cache Ubuntu apt packages.
cache: apt

compiler:
  - gcc
# Disable clang build: doesn't seem to work on Linux.
# (@jeffdonahue: Travis buildbot's failure behavior is similar to what I see
# building on Linux.)
#   - clang

before_install:
  - echo $LANG
  - echo $LC_ALL
  - sudo apt-get -y update
  - sudo apt-get -y install wget git curl python-dev python-numpy libprotobuf-dev libleveldb-dev libsnappy-dev libopencv-dev libboost-all-dev libhdf5-serial-dev protobuf-compiler libatlas-dev libatlas-base-dev bc

install:
  # CMake 2.8.12
<<<<<<< HEAD
  - wget http://www.cmake.org/files/v2.8/cmake-2.8.12.tar.gz -O /tmp/cmake.tar.gz && tar -C /tmp -xvf /tmp/cmake.tar.gz && rm /tmp/cmake.tar.gz
  - cd /tmp/cmake-2.8.12 && ./bootstrap --prefix=/usr && make -j4 &&  sudo make install -j4 &&  cd - #&& rm -r /tmp/cmake-2.8.12
=======
  - wget http://www.cmake.org/files/v2.8/cmake-2.8.12.2-Linux-i386.tar.gz -O /tmp/cmake.tar.gz && tar -C /tmp -xvf /tmp/cmake.tar.gz && rm /tmp/cmake.tar.gz 
  - cd /tmp/cmake-2.8.12.2-Linux-i386 && sudo cp * /usr/ -r && cd - && rm -r /tmp/cmake-2.8.12.2-Linux-i386
>>>>>>> cmake from binaries
    #
  - wget https://google-glog.googlecode.com/files/glog-0.3.3.tar.gz -O /tmp/glog-0.3.3.tar.gz && tar -C /tmp -xzvf /tmp/glog-0.3.3.tar.gz && rm /tmp/glog-0.3.3.tar.gz
  - cd /tmp/glog-0.3.3 && ./configure && make -j4 && sudo make install -j4 && cd -
  - wget https://github.com/schuhschuh/gflags/archive/master.zip -O /tmp/gflags-master.zip && pushd /tmp/ && unzip gflags-master.zip && cd gflags-master && mkdir build && cd build && export CXXFLAGS="-fPIC" && cmake .. && make VERBOSE=1 && sudo make install && popd
  - curl http://developer.download.nvidia.com/compute/cuda/repos/ubuntu1204/x86_64/cuda-repo-ubuntu1204_6.0-37_amd64.deb -o /tmp/cuda_install.deb && sudo dpkg -i /tmp/cuda_install.deb && rm /tmp/cuda_install.deb
  - sudo apt-get -y update
  # Install the minimal CUDA subpackages required to test Caffe build.
  # For a full CUDA installation, add 'cuda' to the list of packages.
  - sudo apt-get -y install cuda-core-6-0 cuda-extra-libs-6-0
  # Create CUDA symlink at /usr/local/cuda
  # (This would normally be created by the CUDA installer, but we create it
  # manually since we did a partial installation.)
  - sudo ln -s /usr/local/cuda-6.0 /usr/local/cuda
  - curl https://gitorious.org/mdb/mdb/archive/7f038d0f15bec57b4c07aa3f31cd5564c88a1897.tar.gz -o /tmp/mdb.tar.gz && tar -C /tmp -xzvf /tmp/mdb.tar.gz && rm /tmp/mdb.tar.gz
  - cd /tmp/mdb-mdb/libraries/liblmdb/ && make -j4 && sudo make install -j4 && cd -

before_script:
  - mv Makefile.config.example Makefile.config
  - export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib
  - export NUM_THREADS=4

script:
  # CMake build.
  - mkdir build
  - cd build
    ## CPU-GPU build
  - cmake -DBUILD_PYTHON=ON -DBUILD_EXAMPLES=ON -DCMAKE_BUILD_TYPE=Release ..
  - make --keep-going --jobs=$NUM_THREADS
  - make clean && rm -rf *
    ## CPU-only build
  - cmake -DBUILD_PYTHON=ON -DBUILD_EXAMPLES=ON -DCMAKE_BUILD_TYPE=Release -DCPU_ONLY=ON ..
  - make --keep-going --jobs=$NUM_THREADS
  - cd test && ./test --gtest_shuffle --gtest_filter="-*GPU*" && cd -
  - make clean && rm -rf *
    ## Cleaning
  - cd ..
  - rm -r build

  # CPU-GPU: build only.
  - export CPU_ONLY=0
  - make --keep-going --jobs=$NUM_THREADS all
  - make clean
  # CPU-only: comprehensive.
  - export CPU_ONLY=1
  - make --keep-going --jobs=$NUM_THREADS all test warn lint
  - make runtest
  - make --jobs=$NUM_THREADS all
  - make --jobs=$NUM_THREADS test
{'fraction_non_alphanumeric': 0.15847469914455561, 'fraction_numerical': 0.03450775699579527, 'mean_word_length': 2.771459814106069, 'pattern_counts': {'":': 0, '<': 17, '<?xml version=': 0, '>': 17, 'https://': 6, 'lorem ipsum': 0, 'www.': 4, 'xml': 0}, 'pii_count': 6, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7405339', 'n_tokens_mistral': 2912, 'n_tokens_neox': 2730, 'n_words': 650}