<commit_before>language: rust
sudo: false
dist: trusty # still in beta, but required for the prebuilt TF binaries

cache:
  cargo: true

rust:
  - stable
  - beta
  - nightly

env:
  global:
    - RUST_BACKTRACE=1
    - CC="gcc-4.9"
    - CXX="g++-4.9"
  matrix:
    - TF_RUST_BUILD_FROM_SRC=true
    - TF_RUST_BUILD_FROM_SRC=false


matrix:
  fast_finish: true
  allow_failures:
    - rust: nightly


install:
  # Install dependencies only if we build tensorflow from source.
  - if [[ "$TF_RUST_BUILD_FROM_SRC" == "true" ]]; then source travis-ci/install.sh; fi
  - if [[ "$TF_RUST_BUILD_FROM_SRC" == "true" ]]; then pip install --user numpy; fi

script:
  - cargo test -vv -j 2 --features tensorflow_unstable
  - cargo run --example regression
  - cargo run --features tensorflow_unstable --example expressions<commit_msg>Travis: Disable building TensorFlow from source<commit_after>language: rust
sudo: false
dist: trusty # still in beta, but required for the prebuilt TF binaries

cache:
  cargo: true

rust:
  - stable
  - beta
  - nightly

env:
  global:
    - RUST_BACKTRACE=1
    - CC="gcc-4.9"
    - CXX="g++-4.9"
  matrix:
    # Building TensorFlow in Travis is not working properly, probably due
    # to resources constraints.
    # - TF_RUST_BUILD_FROM_SRC=true
    - TF_RUST_BUILD_FROM_SRC=false


matrix:
  fast_finish: true
  allow_failures:
    - rust: nightly


install:
  # Install dependencies only if we build tensorflow from source.
  - if [[ "$TF_RUST_BUILD_FROM_SRC" == "true" ]]; then source travis-ci/install.sh; fi
  - if [[ "$TF_RUST_BUILD_FROM_SRC" == "true" ]]; then pip install --user numpy; fi

script:
  - cargo test -vv -j 2 --features tensorflow_unstable
  - cargo run --example regression
  - cargo run --features tensorflow_unstable --example expressions
{'fraction_non_alphanumeric': 0.10602678571428571, 'fraction_numerical': 0.006696428571428571, 'mean_word_length': 3.2387706855791962, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3157970', 'n_tokens_mistral': 624, 'n_tokens_neox': 607, 'n_words': 179}