def convert_reshape(params, w_name, scope_name, inputs, layers, weights, names):
print('<STR_LIT>')<EOL>if names == '<STR_LIT>':<EOL><INDENT>tf_name = '<STR_LIT>' + random_string(<NUM_LIT:4>)<EOL><DEDENT>elif names == '<STR_LIT>':<EOL><INDENT>tf_name = w_name<EOL><DEDENT>else:<EOL><INDENT>tf_name = w_name + str(random.random())<EOL><DEDENT>if len(inputs) > <NUM_LIT:1>:<EOL><INDENT>if layers[inputs[<NUM_LIT:1>]][<NUM_LIT:0>] == -<NUM_LIT:1>:<EOL><INDENT>print('<STR_LIT>')<EOL><DEDENT>reshape = keras.layers.Reshape(layers[inputs[<NUM_LIT:1>] + '<STR_LIT>'], name=tf_name)<EOL>layers[scope_name] = reshape(layers[inputs[<NUM_LIT:0>]])<EOL><DEDENT>else:<EOL><INDENT>if inputs[<NUM_LIT:0>] in layers:<EOL><INDENT>reshape = keras.layers.Reshape(params['<STR_LIT>'][<NUM_LIT:1>:], name=tf_name)<EOL>layers[scope_name] = reshape(layers[inputs[<NUM_LIT:0>]])<EOL><DEDENT>else:<EOL><INDENT>print('<STR_LIT>')<EOL><DEDENT><DEDENT>
Convert reshape layer.

Args:
     params: dictionary with layer parameters
     w_name: name prefix in state_dict
     scope_name: pytorch scope name
     inputs: pytorch node inputs
     layers: dictionary with keras tensors
     weights: pytorch state_dict
     names: use short names for keras layers