Giter Site home page Giter Site logo

Comments (3)

TreeOfEast avatar TreeOfEast commented on May 25, 2024

如果我想利用模型进行虚假新闻检测,进行虚假新闻的筛选,应该修改哪些部分呢

from rumor_detection_2019_ncovex.

JiaxiangBU avatar JiaxiangBU commented on May 25, 2024

时间较远了,你可以关注下 gitbook,

labels = np.array(df1[['ncw_label','fake_label','real_label']])

这里多分类处理。

然后我的 loss func

loss='categorical_crossentropy',

适配多任务的。

im_pred = keras.layers.Dense(3, activation="softmax", name="pred")(x)

计算图的 shape 是 3。

print 为

_________________________________________________________________ pred (Dense) (None, 3)

如果你是二分类,那么修改 3->2 即可,loss 你换成 binary 的交叉熵。

from rumor_detection_2019_ncovex.

JiaxiangBU avatar JiaxiangBU commented on May 25, 2024

时间较远了,你可以关注下 gitbook,

labels = np.array(df1[['ncw_label','fake_label','real_label']])

这里多分类处理。

然后我的 loss func

loss='categorical_crossentropy',

适配多任务的。

im_pred = keras.layers.Dense(3, activation="softmax", name="pred")(x)

计算图的 shape 是 3。

print 为

_________________________________________________________________ pred (Dense) (None, 3)

如果你是二分类,那么修改 3->2 即可,loss 你换成 binary 的交叉熵。

from rumor_detection_2019_ncovex.

Related Issues (2)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.