Skip to content

Commit

Permalink
Debug GitHub low disk space error
Browse files Browse the repository at this point in the history
  • Loading branch information
adamcrume committed Sep 29, 2024
1 parent f0b486d commit 0d247c3
Show file tree
Hide file tree
Showing 2 changed files with 39 additions and 8 deletions.
7 changes: 7 additions & 0 deletions check-disk-space
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/bin/bash

set -euo pipefail

df -h || true
du -sh || true
du -sh /* || true
40 changes: 32 additions & 8 deletions test-all
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,15 @@ function run {
echo
}

function clean {
if [ "$CI" = "true" ]; then
rm -rf target/debug/examples
rm -rf target/debug/incremental
fi
df -h
du -sh target/debug/build/*
}

# Make sure the Tensorflow version in the -sys build script matches the one in
# the run-valgrind script.
version_build_script=`grep "const VERSION" tensorflow-sys/build.rs | sed 's|.*"\([^"]*\)";|\1|g'`
Expand Down Expand Up @@ -51,28 +60,40 @@ export RUSTFLAGS="-Awarnings"
# Keras format, which the C API can't read:
# https://github.com/tensorflow/tensorflow/issues/70514
TF_USE_LEGACY_KERAS=1 run python3 examples/mobilenetv3/create_model.py
run df -h
# TODO(#391): Re-enable: (cd test_resources/library && ./build-test-op)
run cargo fmt --all -- --check
clean
run cargo test -vv -j 2
clean
run cargo test -vv -j 2 --features eager
clean
run cargo test -vv -j 2 --features tensorflow_unstable
clean
run cargo test -vv -j 2 --features ndarray
clean
run cargo run --example regression
clean
run cargo run --example xor
clean
run cargo run --features tensorflow_unstable --example expressions
clean
run cargo run --features eager --example mobilenetv3
clean
run cargo doc --features experimental,tensorflow_unstable,ndarray,eager
clean
run cargo doc --features experimental,tensorflow_unstable,ndarray,eager,private-docs-rs
clean
# TODO(#66): Re-enable: (cd tensorflow-sys && cargo test -vv -j 1)
(cd tensorflow-sys && run cargo run --example multiplication)
(cd tensorflow-sys && run cargo run --example tf_version)
(cd tensorflow-sys && run cargo doc -vv)
(cd tensorflow-sys && run cargo run --example multiplication && clean)
(cd tensorflow-sys && run cargo run --example tf_version && clean)
(cd tensorflow-sys && run cargo doc -vv && clean)

run cargo clippy
(cd tensorflow-sys && run cargo clippy)
(cd tensorflow-op-codegen && run cargo clippy)
(cd tensorflow-proto-codegen && run cargo clippy)
(cd tensorflow-internal-macros && run cargo clippy)
# run cargo clippy
# (cd tensorflow-sys && run cargo clippy)
# (cd tensorflow-op-codegen && run cargo clippy)
# (cd tensorflow-proto-codegen && run cargo clippy)
# (cd tensorflow-internal-macros && run cargo clippy)

for file in $(find . -name target -prune -o -name '*.rs' -print); do
bad_deprecations="$(rustfmt --emit stdout --config max_width=1000 "$file" | grep '#\[deprecated' | grep -E -v '([^"\\]|\\.|"([^"\\]|\\.)*")*since' || true)"
Expand All @@ -88,3 +109,6 @@ for file in $(find . -name target -prune -o -name '*.rs' -print); do
exit 1
fi
done

df -h
du -sh target/debug/build/*

0 comments on commit 0d247c3

Please sign in to comment.