@Namespace(value="torch::nn") @Properties(inherit=torch.class) public class NLLLossOptions extends Pointer
NLLLoss
module.
Example:
NLLLoss model(NLLLossOptions().ignore_index(-100).reduction(torch::kMean));
Pointer.CustomDeallocator, Pointer.Deallocator, Pointer.NativeDeallocator, Pointer.ReferenceCounter
Constructor and Description |
---|
NLLLossOptions()
Default native constructor.
|
NLLLossOptions(long size)
Native array allocator.
|
NLLLossOptions(Pointer p)
Pointer cast constructor.
|
Modifier and Type | Method and Description |
---|---|
NLLLossOptions |
getPointer(long i) |
LongPointer |
ignore_index() |
NLLLossOptions |
position(long position) |
LossReduction |
reduction() |
Tensor |
weight() |
address, asBuffer, asByteBuffer, availablePhysicalBytes, calloc, capacity, capacity, close, deallocate, deallocate, deallocateReferences, deallocator, deallocator, equals, fill, formatBytes, free, getDirectBufferAddress, getPointer, getPointer, getPointer, hashCode, interruptDeallocatorThread, isNull, isNull, limit, limit, malloc, maxBytes, maxPhysicalBytes, memchr, memcmp, memcpy, memmove, memset, offsetAddress, offsetof, offsetof, parseBytes, physicalBytes, physicalBytesInaccurate, position, put, realloc, referenceCount, releaseReference, retainReference, setNull, sizeof, sizeof, toString, totalBytes, totalCount, totalPhysicalBytes, withDeallocator, zero
public NLLLossOptions()
public NLLLossOptions(long size)
Pointer.position(long)
.public NLLLossOptions(Pointer p)
Pointer(Pointer)
.public NLLLossOptions position(long position)
public NLLLossOptions getPointer(long i)
getPointer
in class Pointer
@ByRef @NoException(value=true) public Tensor weight()
@Cast(value="int64_t*") @ByRef @NoException(value=true) public LongPointer ignore_index()
@ByRef @NoException(value=true) public LossReduction reduction()
Copyright © 2024. All rights reserved.