remove enable_bias() method, since the visitor is now a friend

This commit is contained in:
Adrià Arrufat 2021-02-04 17:42:35 +09:00
parent cad7c3fe1b
commit 35b92b1631
2 changed files with 1 additions and 9 deletions

View File

@ -113,7 +113,6 @@ namespace dlib
void set_bias_learning_rate_multiplier(double val) { bias_learning_rate_multiplier = val; }
void set_bias_weight_decay_multiplier(double val) { bias_weight_decay_multiplier = val; }
void disable_bias() { use_bias = false; }
void enable_bias() { use_bias = true; }
bool bias_is_disabled() const { return !use_bias; }
inline dpoint map_input_to_output (
@ -2538,7 +2537,7 @@ namespace dlib
{
const size_t num_params = k_in * conv.num_filters() * conv.nr() * conv.nc() + conv.num_filters();
DLIB_CASSERT(num_params == conv.params.size() + conv.num_filters());
conv.enable_bias();
conv.use_bias = true;
resizable_tensor filters = conv.params;
conv.params.set_size(num_params);
std::copy(filters.begin(), filters.end(), conv.params.begin());

View File

@ -926,13 +926,6 @@ namespace dlib
- bias_is_disabled() returns true
!*/
void enable_bias(
);
/*!
ensures
- bias_is_disabled() returns false
!*/
bool bias_is_disabled(
) const;
/*!