@Name(value="torch::data::DataLoaderBase<JavaCPP_javacpp_0003a_0003aDataset_0003ctorch_0003a_0003aTensor_0002ctorch_0003a_0003aTensor_0003e,JavaCPP_javacpp_0003a_0003aDataset_0003ctorch_0003a_0003aTensor_0002ctorch_0003a_0003aTensor_0003e::BatchType,torch::data::samplers::SequentialSampler::BatchRequestType>") @NoOffset @Properties(inherit=torch.class) public class JavaSequentialDataLoaderBase extends Pointer
Pointer.CustomDeallocator, Pointer.Deallocator, Pointer.NativeDeallocator, Pointer.ReferenceCounter
Constructor and Description |
---|
JavaSequentialDataLoaderBase(Pointer p)
Pointer cast constructor.
|
Modifier and Type | Method and Description |
---|---|
ExampleVectorIterator |
begin()
Returns an iterator into the DataLoader.
|
ExampleVectorIterator |
end()
Returns a special "sentinel" iterator that compares equal with a
non-sentinel iterator once the DataLoader is exhausted.
|
void |
join()
Joins the DataLoader's worker threads and drains internal queues.
|
FullDataLoaderOptions |
options()
Returns the options with which the DataLoader was configured.
|
address, asBuffer, asByteBuffer, availablePhysicalBytes, calloc, capacity, capacity, close, deallocate, deallocate, deallocateReferences, deallocator, deallocator, equals, fill, formatBytes, free, getDirectBufferAddress, getPointer, getPointer, getPointer, getPointer, hashCode, interruptDeallocatorThread, isNull, isNull, limit, limit, malloc, maxBytes, maxPhysicalBytes, memchr, memcmp, memcpy, memmove, memset, offsetAddress, offsetof, offsetof, parseBytes, physicalBytes, physicalBytesInaccurate, position, position, put, realloc, referenceCount, releaseReference, retainReference, setNull, sizeof, sizeof, toString, totalBytes, totalCount, totalPhysicalBytes, withDeallocator, zero
public JavaSequentialDataLoaderBase(Pointer p)
Pointer(Pointer)
.@ByVal public ExampleVectorIterator begin()
OutputIterator
. See
https://en.cppreference.com/w/cpp/named_req/OutputIterator for what this
means. In short: you may increment the iterator and dereference it, but
cannot go back, or step forward more than one position at a time. When the
DataLoader is exhausted, it will compare equal with the special
"sentinel" iterator returned by DataLoader::end()
. Most of the time, you
should only use range-for loops to loop over the DataLoader, but
standard algorithms like std::copy(dataloader.begin(), dataloader.end(),
output_iterator)
are supported too.@ByVal public ExampleVectorIterator end()
public void join()
@Const @ByRef @NoException(value=true) public FullDataLoaderOptions options()
Copyright © 2024. All rights reserved.