GithubHelp home page GithubHelp logo

tammamt / reuters-21578 Goto Github PK

View Code? Open in Web Editor NEW

This project forked from manishkanadje/reuters-21578

0.0 0.0 0.0 7.89 MB

Classification of Text Documents using inductive learning algorithms

Java 100.00%

reuters-21578's Introduction

README

What is this repository for?

This repository has the which implements the Naive Bayes algorithm and Nearest Neighbor algorithm for Reuters-21578 dataset. It classifies the given text document into predefined categories.

How do I get set up?

For running this code you need Apache Solr Server up and running. The Solr server can be installed from "http://lucene.apache.org/solr/". The tutorial for running the Solr server can be obtained from "http://lucene.apache.org/solr/4_8_1/tutorial.html". The code is written in Java. It also requires the jar files containing the Solr API. These files are present in the 'dist' folder of the Solr installation folder.

  1. Install the Apache Solr server if you don't have it as described above.
  2. Replace the schema and stopword files in the Solr-4.7.1/example/solr/collection/conf with the schema and stopword files present in tis folder. If you create a different folder for collection, use path of that folder.
  3. Compile and run the ExtractReuters.java file. This file will upload the and index the Reuters data into the Solr server.
  4. Compile and run StemWords.java file.
  5. By default the code displays results obtained using Naive Bayes algorithm. The results are displayed for entire test dataset. If you want topic wise results, a. Go to line 126 and comment out the for loop and comment out line 127 b. Change the query in line 128 according to topic. This will display the topic wise result.
  6. To use Nearest Neighbor algorithm, substitute function at line 149 with function at 153.
  7. Changing the query present at line 128, will produce different results.

reuters-21578's People

Contributors

manishkanadje avatar

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.