You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Kotlin api should be kept to a thin wrapper of the Java API, using extension functions and codegen wherever possible.
120
+
We do not want to get into a situation where we are maintaining two separate but related APIs.
121
+
122
+
The codegen (`tensorflow-core-kotlin-generator`) is an annotation processor that reads the `@Operator` classes from the `tensorflow-core-api` Java sources.
123
+
If you add operators or re-generate them from the native library, be sure to re-run a `mvn install` in `tensorflow-core-kotlin-api`.
124
+
125
+
#### Formatting
126
+
127
+
The Kotlin API is formatted with ktlint, which is ran on build.
128
+
The build will not auto-format non-generated files.
129
+
You can format them by installing ktlint as the IDE format and using its formatter, or by running `mvn antrun:run@ktlint-format`.
130
+
116
131
## Adding Gradients
117
132
118
133
In some cases, a op supported by Tensorflow Java will not have a gradient defined, resulting in errors like this:
0 commit comments