Show / Hide Table of Contents

Class DataFrame

Data frame to load data like CSV, images and text in binary format. The instance is then send to Train or Predict method

Inheritance
System.Object
DataFrame
DataFrame2D
ImageFrame
Namespace: SiaNet.Data
Assembly: SiaNet.dll
Syntax
public class DataFrame

Properties

| Improve this Doc View Source

Item[UInt32]

Gets the DataFrame at the specified index.

Declaration
public DataFrame this[uint index] { get; }
Parameters
Type Name Description
System.UInt32 index

The index.

Property Value
Type Description
DataFrame

The DataFrame.

| Improve this Doc View Source

Item[UInt32, UInt32]

Gets the DataFrame with the specified start and end index.

Declaration
public DataFrame this[uint start, uint end] { get; }
Parameters
Type Name Description
System.UInt32 start

The start index.

System.UInt32 end

The end index.

Property Value
Type Description
DataFrame

The DataFrame.

Exceptions
Type Condition
System.ArgumentException

End must be greater than start

| Improve this Doc View Source

Shape

Gets the shape of the data frame.

Declaration
public long[] Shape { get; }
Property Value
Type Description
System.Int64[]

The shape.

Methods

| Improve this Doc View Source

GetBatch(Int32, Int32, Int32)

Get batch data with specified start index and size

Declaration
public Tensor GetBatch(int start, int size, int axis = 0)
Parameters
Type Name Description
System.Int32 start

The start.

System.Int32 size

The size.

System.Int32 axis

The axis.

Returns
Type Description
Tensor
| Improve this Doc View Source

GetTensor()

Gets the underlaying tensor instance.

Declaration
public Tensor GetTensor()
Returns
Type Description
Tensor
| Improve this Doc View Source

Head(UInt32, String)

Prints the dataframe, by default first 5 records are printed. Helpful to understand the data structure.

Declaration
public void Head(uint count = 5U, string title = "")
Parameters
Type Name Description
System.UInt32 count

The count of records to print.

System.String title

The title to display.

| Improve this Doc View Source

Reshape(Int64[])

Reshapes the data frame to specified new shape.

Declaration
public void Reshape(params long[] newShape)
Parameters
Type Name Description
System.Int64[] newShape

The new shape.

| Improve this Doc View Source

ToFrame(Tensor)

Converts to tensor to a data frame.

Declaration
public virtual void ToFrame(Tensor t)
Parameters
Type Name Description
Tensor t

The t.

  • Improve this Doc
  • View Source
Back to top Generated by DocFX