Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions docs/tools/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
GitPython
requests
tensorflow-docs
29 changes: 25 additions & 4 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -546,16 +546,37 @@
</plugin>
<plugin>
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.6.0</version>
<version>3.12.0</version>
<configuration>
<overview>./docs/overview.md</overview>
<!--<includeDependencySources>true</includeDependencySources>-->
<bottom>Copyright 2015, 2025 The TensorFlow Authors. All Rights Reserved.</bottom>
<additionalJOptions>
<additionalJOption>-Xmaxerrs</additionalJOption>
<additionalJOption>65536</additionalJOption>
<additionalJOption>-Xmaxwarns</additionalJOption>
<additionalJOption>65536</additionalJOption>
</additionalJOptions>
<failOnError>false</failOnError>
<minmemory>256m</minmemory>
<maxmemory>2048m</maxmemory>
<links>
<link>https://protobuf.dev/reference/java/api-docs</link>
<link>https://bytedeco.org/javacpp/apidocs</link>
</links>
</configuration>
<executions>
<execution>
<id>javadoc-site</id>
<goals>
<goal>javadoc</goal>
</goals>
</execution>
<execution>
<id>attach-javadocs</id>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<quiet>true</quiet>
</configuration>
</execution>
</executions>
</plugin>
Expand Down
24 changes: 0 additions & 24 deletions tensorflow-core/tensorflow-core-api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -220,30 +220,6 @@
</executions>
</plugin>

<plugin>
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.6.0</version>
<executions>
<execution>
<id>attach-javadocs</id>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<additionalJOptions>
<additionalJOption>-Xmaxerrs</additionalJOption>
<additionalJOption>65536</additionalJOption>
<additionalJOption>-Xmaxwarns</additionalJOption>
<additionalJOption>65536</additionalJOption>
</additionalJOptions>
<failOnError>false</failOnError>
<minmemory>256m</minmemory>
<maxmemory>2048m</maxmemory>
</configuration>
</execution>
</executions>
</plugin>

<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>exec-maven-plugin</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
limitations under the License.
=======================================================================
*/

/** Core module implementing the TensorFlow Java API and operator definitions. */
module tensorflow {
requires transitive org.tensorflow.ndarray;
requires transitive tensorflow.nativelib;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,11 @@
import static org.tensorflow.internal.c_api.global.tensorflow.TF_TString_GetSize;

import java.nio.ReadOnlyBufferException;
import java.util.function.Function;
import org.bytedeco.javacpp.BytePointer;
import org.bytedeco.javacpp.Loader;
import org.bytedeco.javacpp.Pointer;
import org.bytedeco.javacpp.PointerScope;
import org.tensorflow.internal.c_api.TF_TString;
import org.tensorflow.ndarray.NdArray;
import org.tensorflow.ndarray.buffer.DataBuffer;
import org.tensorflow.ndarray.impl.buffer.AbstractDataBuffer;
import org.tensorflow.ndarray.impl.buffer.Validator;
Expand All @@ -40,10 +38,9 @@
* <p>The values are stored as an array of {@link TF_TString}, internally wrapped with {@code
* tensorflow::tstring}, which is essentially a portable version of {@code std::string}.
*
* <p>The data of the buffer must be initialized only once, by calling {@link #init(NdArray,
* Function)}, and the buffer must have been allocated with enough space (use {@link
* #computeSize(NdArray, Function)} priory to know exactly how many bytes are required to store the
* data).
* <p>The data of the buffer must be initialized only once, by calling {@link #init}, and the buffer
* must have been allocated with enough space (use {@link #computeSize} priory to know exactly how
* many bytes are required to store the data).
*
* <p>After its data has been initialized, the buffer is read-only as it is not possible to change
* safely a value without reinitializing the whole data.
Expand All @@ -66,8 +63,8 @@ public static <T> long computeSize(ByteSequenceProvider<?> byteSequenceProvider)
*
* <p>While it is not enforced programmatically, it is mandatory that this method is called only
* once after the creation of the buffer. The buffer must have been allocated according to the
* same set of data, calling {@link #computeSize(NdArray, Function)} priory to make sure there is
* enough space to store it.
* same set of data, calling {@link #computeSize} priory to make sure there is enough space to
* store it.
*
* @param byteSequenceProvider produces sequences of bytes to use as the tensor data
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
import org.tensorflow.types.TUint16;

/**
* Maps memory of {@link org.tensorflow.proto.DataType#DT_Uint16} tensors to a n-dimensional data
* Maps memory of {@link org.tensorflow.proto.DataType#DT_UINT16} tensors to a n-dimensional data
* space.
*/
public final class TUint16Mapper extends TensorMapper<TUint16> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,18 @@
limitations under the License.
=======================================================================
*/

/**
* Code to generate the Java side implementations of TensorFlow's ops based on the TensorFlow op
* definition files.
*/
module tensorflow.generator {
requires tensorflow.nativelib;
requires java.compiler;
requires transitive java.compiler;
requires com.github.javaparser.core;
requires com.google.protobuf;
requires com.google.common;
requires com.squareup.javapoet;
requires transitive com.squareup.javapoet;
requires org.commonmark;
requires spring.core;

Expand Down
28 changes: 0 additions & 28 deletions tensorflow-core/tensorflow-core-native/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -639,34 +639,6 @@
</execution>
</executions>
</plugin>

<plugin>
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.7.0</version>
<executions>
<execution>
<id>attach-javadocs</id>
<goals>
<goal>jar</goal>
</goals>
<configuration>
<additionalJOptions>
<additionalJOption>-Xmaxerrs</additionalJOption>
<additionalJOption>65536</additionalJOption>
<additionalJOption>-Xmaxwarns</additionalJOption>
<additionalJOption>65536</additionalJOption>
</additionalJOptions>
<failOnError>false</failOnError>
<minmemory>256m</minmemory>
<maxmemory>2048m</maxmemory>
<links>
<link>https://protobuf.dev/reference/java/api-docs</link>
<link>http://bytedeco.org/javacpp/apidocs</link>
</links>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
limitations under the License.
=======================================================================
*/

/** Native interop with the TensorFlow C API. */
module tensorflow.nativelib {
requires transitive org.bytedeco.javacpp;
requires transitive com.google.protobuf;
Expand Down
6 changes: 4 additions & 2 deletions tensorflow-framework/src/main/java/module-info.java
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,11 @@
limitations under the License.
=======================================================================
*/

/** Higher level TensorFlow framework containing model definition and training operations. */
module tensorflow.framework {
requires tensorflow;
requires org.tensorflow.ndarray;
requires transitive tensorflow;
requires transitive org.tensorflow.ndarray;

exports org.tensorflow.framework.activations;
exports org.tensorflow.framework.constraints;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,6 @@ private static <T extends TNumber> Operand<T> reduceWeightedLoss(
*
* @param tf the TensorFlow Ops
* @param losses <code>Operand</code> whose elements contain individual loss measurements.
* @param numElements The number of measurable elements in <code>losses</code>.
* @param <T> the data type of the losses
* @return A scalar representing the mean of <code>losses</code>. If <code>numElements</code> is
* zero, then zero is returned.
Expand Down
Loading