Giter Site home page Giter Site logo

Comments (2)

siddsax avatar siddsax commented on May 27, 2024

Hi Negacy

The dataset is actually a python pickle file. Upon loading, it consists of 4 lists. 1st and 2nd are training and test sets. Each instance is a dictionary in those lists with keys ('text', 'num_words', 'split', 'catgy', 'Id').
The third item in the list is a word key which has keys as all the words in the dataset and value as a corresponding serial number for those words. The last item of the list are set of labels in the dataset but they are not used. Have a look at this file https://github.com/siddsax/XML-CNN/blob/master/utils/data_helpers.py for more help tracking back from load_data function

from xml-cnn.

negacy avatar negacy commented on May 27, 2024

Thanks, @siddsax:

So, what I have is list of documents and their labels; for example, ['this is first document', ['label-1', 'label-2', 'label-99']], ['this is second document', 'label-7'] ... etc. I think I need to modify line 107 and 108 of the script. But, what would be the values of m and n? Is m the maximum number of tokens in a document? n is the maximum number of labels assigned to a document in the training/testing?

from xml-cnn.

Related Issues (6)

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.