Skip to content

Commit

Permalink
Update tensorflow version and fix for sbt snapshots (#42)
Browse files Browse the repository at this point in the history
* Update tensorflow version and fix for sbt snapshots

* Fix formatting

* Try and fix CI
  • Loading branch information
ekrich authored Nov 28, 2022
1 parent 7fa96e4 commit b2ac3e0
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
6 changes: 4 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,14 @@ jobs:
- name: Setup (Linux)
if: startsWith(matrix.os, 'ubuntu')
run: |
curl -fsSL https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-cpu-linux-x86_64-2.10.0.tar.gz \
curl -fsSL https://storage.googleapis.com/tensorflow/libtensorflow/libtensorflow-cpu-linux-x86_64-2.11.0.tar.gz \
-o ~/libtensorflow.tar.gz
mkdir -p ~/tensorflow && tar -xzf ~/libtensorflow.tar.gz -C ~/tensorflow
- name: Setup (macOS)
if: startsWith(matrix.os, 'macos')
run: brew install libtensorflow
run: |
brew update
brew install libtensorflow
- name: Run tests (Linux) Java ${{ matrix.java }}
if: startsWith(matrix.os, 'ubuntu')
run: |
Expand Down
2 changes: 1 addition & 1 deletion project/plugins.sbt
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
resolvers += Resolver.sonatypeRepo("snapshots")
resolvers ++= Resolver.sonatypeOssRepos("snapshots")

// Current releases
addSbtPlugin("org.scala-native" % "sbt-scala-native" % "0.4.9")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import org.ekrich.tensorflow.unsafe.tensorflowEnums._

class TensorflowTest {

val tfVersion = "2.10"
val tfVersion = "2.11"

type DeallocateTensor = CFuncPtr3[Ptr[Byte], CSize, Ptr[Byte], Unit]

Expand All @@ -27,7 +27,8 @@ class TensorflowTest {
Zone { implicit z =>
val reportVersion = fromCString(TF_Version())
println(s"Tensorflow version: ${reportVersion}")
assert(reportVersion.startsWith(tfVersion))
assertTrue(s"Looking for version: $tfVersion",
reportVersion.startsWith(tfVersion))
}
}
@Test def TF_ExampleTest(): Unit = {
Expand Down

0 comments on commit b2ac3e0

Please sign in to comment.