8000 global_loss += tf.reduce_mean(tf.square(global_out - global_label)) / len(labels); global_loss /= 2;.so damn hard to understand · Issue #81 · chenyilun95/tf-cpn · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
global_loss += tf.reduce_mean(tf.square(global_out - global_label)) / len(labels); global_loss /= 2;.so damn hard to understand #81
Open
@gcl1991

Description

@gcl1991
global_loss = 0.
for i, (global_out, label) in enumerate(zip(global_outs, labels)):
    global_label = label * tf.to_float(tf.greater(tf.reshape(valids, (-1, 1, 1, cfg.nr_skeleton)), 1.1))
    global_loss += tf.reduce_mean(tf.square(global_out - global_label)) / len(labels)
global_loss /= 2.

QAQ can somebody help me
why / len(labels) and global_loss /= 2 ?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      28FC
      0