Skip to content

Commit

Permalink
Implemented OS switch so macOS builds use CPU version of TensorFlow.
Browse files Browse the repository at this point in the history
Fixes #313.
  • Loading branch information
Spiess committed Jul 26, 2022
1 parent 9e792a6 commit 166123f
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion cineast-core/build.gradle
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import org.gradle.nativeplatform.platform.internal.DefaultNativePlatform

repositories {
maven {
url "https://oss.sonatype.org/content/repositories/snapshots/"
Expand Down Expand Up @@ -96,7 +98,10 @@ dependencies {
implementation 'org.mockito:mockito-inline:4.5.1'

/** Tensorflow (Java). */
api group: "org.tensorflow", name: "tensorflow-core-platform-gpu", version: version_tensorflow
if (DefaultNativePlatform.currentOperatingSystem.isMacOsX())
api group: "org.tensorflow", name: "tensorflow-core-platform", version: version_tensorflow
else
api group: "org.tensorflow", name: "tensorflow-core-platform-gpu", version: version_tensorflow


/** Apache Commons Libraries */
Expand Down

0 comments on commit 166123f

Please sign in to comment.