Skip to content

Unable to run manager.py to generate pages #137

@Semyazz

Description

@Semyazz

I tried to run python explainshell/manager.py --log info manpages/1/echo.1.gz but I got the following error

Traceback (most recent call last):
  File "explainshell/manager.py", line 203, in <module>
    sys.exit(main(args.files, args.db, args.host, args.overwrite, args.drop, args.verify))
  File "explainshell/manager.py", line 184, in main
    m = manager(dbhost, dbname, gzs, overwrite, drop)
  File "explainshell/manager.py", line 32, in __init__
    self.classifier.train()
  File "/opt/explainshell/explainshell/algo/classifier.py", line 74, in train
    self.classifier = c.train(trainfeats, **self.classifier_args)
  File "/usr/local/lib/python2.7/dist-packages/nltk/classify/naivebayes.py", line 220, in train
    label_probdist = estimator(label_freqdist)
  File "/usr/local/lib/python2.7/dist-packages/nltk/probability.py", line 803, in __init__
    LidstoneProbDist.__init__(self, freqdist, 0.5, bins)
  File "/usr/local/lib/python2.7/dist-packages/nltk/probability.py", line 683, in __init__
    'must have at least one bin.')
ValueError: A ELE probability distribution must have at least one bin.

Any idea what might be wrong? I've never used that nltk stuff.

Besides, can I generate explainshell pages for any man page on my OS (ubuntu)? or some manual work is required to make it work/display everything correclty?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions