ramjet.models

Code for network architectures.

Module Contents

class SanityCheckNetwork[source]

Bases: tensorflow.keras.Sequential

A network consisting of a single fully connected layer.

__init__(self)[source]
class SimpleCubeCnn[source]

Bases: tensorflow.keras.Sequential

A simple 3D CNN for TESS data cubes.

__init__(self)[source]
class SimpleLightcurveCnn[source]

Bases: tensorflow.keras.Model

A simple 1D CNN for lightcurves.

__init__(self)[source]
call(self, inputs, training=False, mask=None)[source]

The forward pass of the layer.

Parameters:
  • inputs – The input tensor.
  • training – A boolean specifying if the layer should be in training mode.
  • mask – A mask for the input tensor.
Returns:

The output tensor of the layer.

class SimpleFfiLightcurveCnn[source]

Bases: tensorflow.keras.Model

A simple 1D CNN for FFI lightcurves.

__init__(self)[source]
call(self, inputs, training=False, mask=None)[source]

The forward pass of the layer.

Parameters:
  • inputs – The input tensor.
  • training – A boolean specifying if the layer should be in training mode.
  • mask – A mask for the input tensor.
Returns:

The output tensor of the layer.

class SmallFfiLightcurveCnn[source]

Bases: tensorflow.keras.Model

A simple 1D CNN for FFI lightcurves.

__init__(self)[source]
call(self, inputs, training=False, mask=None)[source]

The forward pass of the layer.

Parameters:
  • inputs – The input tensor.
  • training – A boolean specifying if the layer should be in training mode.
  • mask – A mask for the input tensor.
Returns:

The output tensor of the layer.

class SimpleLightcurveLstm[source]

Bases: tensorflow.keras.Model

A simple LSTM model for lightcurves.

__init__(self)[source]
call(self, inputs, training=False, mask=None)[source]

The forward pass of the layer.

Parameters:
  • inputs – The input tensor.
  • training – A boolean specifying if the layer should be in training mode.
  • mask – A mask for the input tensor.
Returns:

The output tensor of the layer.

class SimpleLightcurveCnnPerTimeStepLabel[source]

Bases: tensorflow.keras.Model

A simple 1D CNN for lightcurves.

__init__(self)[source]
call(self, inputs, training=False, mask=None)[source]

The forward pass of the layer.

Parameters:
  • inputs – The input tensor.
  • training – A boolean specifying if the layer should be in training mode.
  • mask – A mask for the input tensor.
Returns:

The output tensor of the layer.

class Conv1DTranspose(filters, kernel_size, strides=1, *args, **kwargs)[source]

Bases: tensorflow.keras.layers.Layer

A 1D transposed convolutional layer.

__init__(self, filters, kernel_size, strides=1, *args, **kwargs)[source]
build(self, input_shape)[source]

Builds the layer.

Parameters:input_shape – The input tensor shape.
call(self, x, training=False, mask=None)[source]

The forward pass of the layer.

Parameters:
  • x – The input tensor.
  • training – A boolean specifying if the layer should be in training mode.
  • mask – A mask for the input tensor.
Returns:

The output tensor of the layer.

compute_output_shape(self, input_shape)[source]

The output shape of the layer.

Parameters:input_shape
Returns:
class ConvolutionalLstm[source]

Bases: tensorflow.keras.Model

A convolutional LSTM network.

__init__(self)[source]
call(self, inputs, training=False, mask=None)[source]

The forward pass of the layer.

Parameters:
  • inputs – The input tensor.
  • training – A boolean specifying if the layer should be in training mode.
  • mask – A mask for the input tensor.
Returns:

The output tensor of the layer.