Nicotine
Nicotine
> > hi 请教个问题 ESMM模型预估的ctr看起来正常 但是预估cvr全为0 会是什么原因呢? > > 我也遇到这个问题了,目前已解决,方式是:build_mode()函数只返回net,把计算logits的步骤放在my_model()函数里搞, > > ```python > def my_model(features, labels, mode, params): > with tf.variable_scope('ctr_model'): > last_ctr_layer = build_mode(features, mode, params) > with...
可能输入里没有 tfrecords 文件。把 train_input_fn 的函数第一句改成 dataset = tf.data.TFRecordDataset(filenames),然后 filename 里包含 tfrecords ,比如”../../cvr_train.tfrecords“ ,cvr 结果就不为 0
> > 可能输入里没有 tfrecords 文件。把 train_input_fn 的函数第一句改成 dataset = tf.data.TFRecordDataset(filenames),然后 filename 里包含 tfrecords ,比如”../../cvr_train.tfrecords“ ,cvr 结果就不为 0 > > 你有数据集吗? 我用的自己的数据集
> Maybe your picture is a gray image, you should use a color picture 都是调用MNIST那个接口,从哪里可以下载到彩色的呢?
之前改过了,transform = transforms.Compose([ transforms.ToTensor(), transforms.Normalize(mean=0.5, std=0.5)]) 又报错 too many indices for tensor of dimension 0 我把后面那个 for i, (images, _) in enumerate(data_loader): 改成 for i, images in enumerate(data_loader): 也不对
这样改就好了 transform = transforms.Compose([ transforms.ToTensor(), transforms.Normalize([0.5], [0.5])])