void oneoff2(char *cfgfile, char *weightfile, char *outfile, int l) { gpu_index = -1; network *net = parse_network_cfg(cfgfile); if(weightfile){ load_weights_upto(net, weightfile, 0, net->n); load_weights_upto(net, weightfile, l, net->n); } *net->seen = 0; save_weights_upto(net, outfile, net->n); free_network(net); }
void partial(char *cfgfile, char *weightfile, char *outfile, int max) { network net = parse_network_cfg(cfgfile); if(weightfile){ load_weights_upto(&net, weightfile, max); } net.seen = 0; save_weights(net, outfile); }
static void partial(char *cfgfile, char *weightfile, char *outfile, int max) { gpu_index = -1; network net = parse_network_cfg(cfgfile); if(weightfile){ load_weights_upto(&net, weightfile, max); } *net.seen = 0; save_weights_upto(net, outfile, max); }
void load_weights(network *net, char *filename) { load_weights_upto(net, filename, net->n); }