public BidirectionalCell(BaseRNNCell l_cell, BaseRNNCell r_cell, string output_prefix = "bi_", RNNParams @params = null) : base("", @params) { this._output_prefix = output_prefix; this._override_cell_params = @params != null; if (this._override_cell_params) { Debug.Assert(l_cell._own_params != null && r_cell._own_params, "Either specify params for BidirectionalCell or child cells, not both."); foreach (var item in this.Params._params) { l_cell.Params._params[item.Key] = item.Value; r_cell.Params._params[item.Key] = item.Value; } } foreach (var item in l_cell.Params._params) { this.Params._params[item.Key] = item.Value; } foreach (var item in r_cell.Params._params) { this.Params._params[item.Key] = item.Value; } this._cells.Add(l_cell); this._cells.Add(r_cell); }
public ZoneoutCell(BaseRNNCell base_cell, float zoneout_outputs = 0, float zoneout_states = 0) : base(base_cell) { Debug.Assert(!(base_cell is FusedRNNCell), "FusedRNNCell doesn't support zoneout. Please unfuse first."); Debug.Assert(!(base_cell is BidirectionalCell), "BidirectionalCell doesn't support zoneout since it doesn't support step. Please add ZoneoutCell to the cells underneath instead."); Debug.Assert(!(base_cell is SequentialRNNCell), "Bidirectional SequentialRNNCell doesn't support zoneout. Please add ZoneoutCell to the cells underneath instead."); this.zoneout_outputs = zoneout_outputs; this.zoneout_states = zoneout_states; this.prev_output = null; }
public void Add(BaseRNNCell cell) { this._cells.Add(cell); if (this._override_cell_params) { Debug.Assert(cell._own_params, "Either specify params for SequentialRNNCell or child cells, not both."); foreach (var item in this.Params._params) { cell.Params._params[item.Key] = item.Value; } } foreach (var item in cell.Params._params) { this.Params._params[item.Key] = item.Value; } }
public ModifierCell(BaseRNNCell base_cell) : base("", null) { base_cell._modified = true; this.base_cell = base_cell; }
public ResidualCell(BaseRNNCell base_cell) : base(base_cell) { }
public ZoneoutCell(BaseRNNCell base_cell, float zoneout_outputs = 0, float zoneout_states = 0) : base(base_cell) { throw new NotImplementedException(); }
public ResidualCell(BaseRNNCell base_cell) : base(base_cell) { throw new NotImplementedException(); }
public BidirectionalCell(BaseRNNCell l_cell, BaseRNNCell r_cell, string output_prefix = "bi_", RNNParams @params = null) : base("", @params) { throw new NotImplementedException(); }
public ModifierCell(BaseRNNCell base_cell) : base("", null) { }
public void Add(BaseRNNCell cell) { throw new NotImplementedException(); }