Skip to main content

A ridiculously simple search engine factory

Project description

grub

A ridiculously simple search engine

Example: Search code

from grub import SearchStore
import sklearn  # instead of talking any file, let's search the files of sklearn itself!

path_format = os.path.dirname(sklearn.__file__) + '{}.py'
search = SearchStore(path_format)

Let's search for ANN. That stands for Artificial Neural Networks. Did you know? Well search figures it out, pretty early, that I was talking about neural networks.

search('ANN')  
array(['sklearn/tree/_export.py', 'sklearn/linear_model/_least_angle.py',
       'sklearn/feature_selection/_base.py',
       'sklearn/feature_selection/tests/test_variance_threshold.py',
       'sklearn/neural_network/tests/test_stochastic_optimizers.py',
       'sklearn/neural_network/__init__.py',
       'sklearn/neural_network/_stochastic_optimizers.py',
       'sklearn/neural_network/_multilayer_perceptron.py',
       'sklearn/neural_network/rbm.py',
       'sklearn/neural_network/tests/test_rbm.py'], dtype='<U75')

Let's search for something more complicated. Like a sentence. The results show promise promises: It's about calibration, but related are robustness, feature selection and validation...

search('how to calibrate the estimates of my classifier')  
array(['sklearn/covariance/_robust_covariance.py',
       'sklearn/svm/_classes.py',
       'sklearn/covariance/_elliptic_envelope.py',
       'sklearn/neighbors/_lof.py', 'sklearn/ensemble/_iforest.py',
       'sklearn/feature_selection/_rfe.py', 'sklearn/calibration.py',
       'sklearn/model_selection/_validation.py',
       'sklearn/ensemble/_forest.py', 'sklearn/ensemble/_gb.py'],
      dtype='<U75')

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

grub-0.1.5.tar.gz (22.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

grub-0.1.5-py3-none-any.whl (14.7 kB view details)

Uploaded Python 3

File details

Details for the file grub-0.1.5.tar.gz.

File metadata

  • Download URL: grub-0.1.5.tar.gz
  • Upload date:
  • Size: 22.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.13 {"installer":{"name":"uv","version":"0.11.13","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for grub-0.1.5.tar.gz
Algorithm Hash digest
SHA256 263ef3bdf4e93d1323ccc1148ae828b23d796cfd3e635b0605f472ecf37a19ae
MD5 bc2c5774e441c0f86b4bf59dd7cc60de
BLAKE2b-256 af93647a7e7bd8bd37a0bbc4a6acbcfc3d3ae4a77070a51c9568411ebf28ff68

See more details on using hashes here.

File details

Details for the file grub-0.1.5-py3-none-any.whl.

File metadata

  • Download URL: grub-0.1.5-py3-none-any.whl
  • Upload date:
  • Size: 14.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.13 {"installer":{"name":"uv","version":"0.11.13","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for grub-0.1.5-py3-none-any.whl
Algorithm Hash digest
SHA256 a475e925955a00b94d764fffd422ccbeddb2c00a8ba234276e8398769b03e65c
MD5 e92a27e45ea231b8ee57a06e5f28dde9
BLAKE2b-256 13cfaa7c4a36efc4a31b4e3a96028fe8cdf45d51348421bbd3cace314d650e44

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page