MCPcopy Index your code
hub / github.com/PaddlePaddle/PaddleRec / network

Method network

tools/feature_importance.py:87–105  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

85 fleet.init()
86
87 def network(self):
88 self.model = get_model(self.config)
89 self.input_data = self.model.create_feeds()
90 self.metrics = self.model.net(self.input_data)
91 logger.info("cpu_num: {}".format(os.getenv("CPU_NUM")))
92
93 thread_stat_var_names = [
94 self.model.auc_stat_list[2].name, self.model.auc_stat_list[3].name
95 ]
96 thread_stat_var_names += [i.name for i in self.model.metric_list]
97 thread_stat_var_names = list(set(thread_stat_var_names))
98 self.config['stat_var_names'] = thread_stat_var_names
99
100 self.metric_list = list(self.model.auc_stat_list) + list(
101 self.model.metric_list)
102 self.metric_types = ["int64"] * len(self.model.auc_stat_list) + [
103 "float32"
104 ] * len(self.model.metric_list)
105 self.model.create_optimizer(get_strategy(self.config))
106
107 def run_server(self):
108 logger.info("Run Server Begin")

Callers 1

runMethod · 0.95

Calls 5

get_modelFunction · 0.90
get_strategyFunction · 0.90
create_feedsMethod · 0.45
netMethod · 0.45
create_optimizerMethod · 0.45

Tested by

no test coverage detected