Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7724301
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T04:39:13+00:00 2026-06-01T04:39:13+00:00

I am trying to exploit hadoop to train multiple models . My data are

  • 0

I am trying to exploit hadoop to train multiple models . My data are small enough to fit in memory so i want to have one model trained in every map task.

My problem is that when i have finished training my model, i need to send it to the reducer. I am using Weka to train the model. I don’t want to start looking how to implement the Writable interface in Weka classes, because it needs a lot of effort. I am looking for a simple way to do this.

The Classifier class in Weka implements the Serializable interface. How can i send this object to the reducer?

        edits

Here is the link that mentions weka objects serialization: http://weka.wikispaces.com/Serialization

Here is what my code looks like:
Configuring the job(only a part of the configuration is posted):

       conf.set("io.serializations","org.apache.hadoop.io.serializer.JavaSerialization," + "org.apache.hadoop.io.serializer.WritableSerialization"); 
       job.setOutputKeyClass(Text.class);
       job.setOutputValueClass(Classifier.class);

Map function:

     //load dataset in data variable
     Classifier tree=new J48();
     tree.buildClassifier();
     context.write(new Text("whatever"), tree);

My Map class extends Mapper (Object,Text,Text,Classifier)

But i am getting this error:

     java.lang.NullPointerException
at org.apache.hadoop.io.serializer.SerializationFactory.getSerializer(SerializationFactory.java:73)
at org.apache.hadoop.mapred.MapTask$MapOutputBuffer.<init>(MapTask.java:964)
at org.apache.hadoop.mapred.MapTask$NewOutputCollector.<init>(MapTask.java:673)
at org.apache.hadoop.mapred.MapTask.runNewMapper(MapTask.java:755)
at org.apache.hadoop.mapred.MapTask.run(MapTask.java:369)
at org.apache.hadoop.mapred.Child$4.run(Child.java:259)
at java.security.AccessController.doPrivileged(Native Method)
at javax.security.auth.Subject.doAs(Subject.java:416)
at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1059)
at org.apache.hadoop.mapred.Child.main(Child.java:253)

What i am doing wrong??

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T04:39:15+00:00Added an answer on June 1, 2026 at 4:39 am

    You can define your own serialization mechanism

    • http://www.lexemetech.com/2008/07/rpc-and-serialization-with-hadoop.html
    • https://issues.apache.org/jira/browse/HADOOP-1986

    I think it resolves around implementing the Serialization interface, and defining your implementation in the io.serializations configuration property

    In your case, if you just want to use java serialization, set this property to:

    • org.apache.hadoop.io.serializer.JavaSerialization
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Trying to figure out how to exploit the CSharpCodeProvider to compile string data at
Trying to get comfortable with jQuery and I have encountered some sample code that
I'm trying to figure out this problem for one of my comp sci classes,
I'm trying to handle this possible exploit and wondering what is the best way
I'm trying to exploit my format string bug, which lies in this program: #include
Greetings. I have a java method that I consider expensive, and I'm trying to
I currently perform penetration testing of ASP.NET application and trying to exploit Padding Oracle
I am trying to learn to exploit simple bufferover flow technique on Backtrack Linux.
I have a situation where I want encoded slashes in a URI ( %2F
I'm trying a little experiment in haskell, wondering if it is possible to exploit

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.