vitords / hoeffdingtree Goto Github PK
View Code? Open in Web Editor NEWA Python implementation of the Hoeffding Tree algorithm.
License: GNU General Public License v3.0
A Python implementation of the Hoeffding Tree algorithm.
License: GNU General Public License v3.0
File "d:\classification_rules_big_data\code\HoeffdingTree-master\main.py", line 2, in
from hoeffdingtree import *
File "d:\classification_rules_big_data\code\HoeffdingTree-master\hoeffdingtree.py", line 5, in
from core.attribute import Attribute
File "d:\classification_rules_big_data\code\HoeffdingTree-master\core\attribute.py", line 3, in
class Attribute(object):
File "d:\classification_rules_big_data\code\HoeffdingTree-master\core\attribute.py", line 151, in Attribute
def set_numeric_range(self, lower_bound=-math.inf, upper_bound=math.inf):
AttributeError: 'module' object has no attribute 'inf'
Hi,sir
I want know, what used data set for train and test, I need use for experiments.
I want to help,what was type data set used code.
Thanks .
Mohammadi
Hi,Dear
it is output for HIGGS dataset, do you know correct by output?
Do you know what I can be doing wrong?
Thanks in advance.
_str nomodel
(11010001.0)
Dataset 'New dataset'
Attributes: ['0', '1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23', '24', '25', '26', '27', '28']
Class attribute: 0
Total instances: 10000
(11010001.0)
Instance
From dataset: New dataset
Attribute values: ['0.00E+000', '5.47E-001 ', '-3.50E-001', '-6.47E-001', '2.04E+000', '2.76E-001', '5.45E-001', '8.39E-001', '1.73E+000', '0.00E+000', '6.53E-001', '1.47E+000', '1.24E+000', '0.00E+000', '7.86E-001', '-4.44E-002', '-1.02E+000', '2.55E+000', '4.19E-001', '-6.29E-001', '1.57E+000', '3.10E+000', '6.89E-001', '8.67E-001', '1.08E+000', '6.64E-001', '3.54E-001', '5.80E-001', '8.17E-001']
Class: 0.00E+000
[ ]
Process finished with exit code 0
Hi vitords
I used to attached files for experiments but can`t get tree model.
I have another question: how to calculate "pre_dist" and "post_dist" properly for my dataset?
main.txt
dataset and main.txt send email`s
dataset_file.txt
File "d:\A_start_oct30_2016\moa\HoeffdingTree-master\main.py", line 106, in
main()
File "d:\A_start_oct30_2016\moa\HoeffdingTree-master\main.py", line 79, in main
vfdt.set_set_hoeffding_tie_threshold(0.05)
builtins.AttributeError: 'HoeffdingTree' object has no attribute 'set_set_hoeffding_tie_threshold'
it give error
builtins.FileNotFoundError: [Errno 2] No such file or directory: 'dataset_file.csv'
so it would be nice to have data file and results of classification to make sure it runs corectly
for example you may use the same data as in
https://github.com/blazs/HoeffdingTree
housing.dat
housing-100K.dat
sample.dat
sea.dat
winnow.dat
Dear vitords,
I have been using your VFDT (thanks for your great work), and I have found that when I have a new instance and I want to know the predicted class, the method distribution_for_instance
should provides the class probabilities for this new instance. But, I have found that the class probabilities are always distributed proportionally to the number of values โโof the class.
For example: if my class have these values [0,1], the method always gives [0.5,0.5]. If my class have these values [0,1,2], the method always gives [0.33,0.33,0.33], etc.
Do you know what I can be doing wrong?
Thanks in advance.
Hello, :-)
file ht/gaussianconditionalsufficientstats.py:
in the function "probability_density(self, value)", the code follows:
return (1.0 / (self.CONST * std_dev)) * math.exp(-(diff * diff / (2.0 * self._variance)))
I think this code means the probability density function of Gaussian distribution, but the self.CONST here actually is math.log(2 * math.pi)
, should it be math.sqrt(2 * math.pi)
?
please point it out if I am wrong, thanks
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.