Download Shareware and Freeware Software for Windows, Linux, Macintosh, PDA

line Home  |  About Us  |  Link To Us  |  FAQ  |  Contact

Serving Software Downloads in 976 Categories, Downloaded 29.877.565 Times

magpy 0.3.0

  Date Added: September 05, 2010  |  Visits: 494

magpy

Report Broken Link
Printer Friendly Version


Product Homepage
Download (71 downloads)



Magpy is a Python wrapper for the mg search engine. magpy module features fast full text sarch, indexing and boolean queries. Both mg and magpy are released under the GPL (General Public License). Installation: To install magpy from source, extract the archive magpy-*.tar.gz, and run the following commands: ./configure python setup.py build python setup.py install Usage: The following script demonstrates a simple search frontend: #!/usr/bin/python import mgindexer import mgquery import sys store = mgquery.MGSearchStore("/tmp/data","alice") while 1: query = sys.stdin.readline() q = store.newQuery(query) print "Searching for",query,"(words",q.words(),")" for docnum,ranking in q.execute(): print "Document",docnum,"matches (Ranking",ranking,")" Before this works, you first have to create search store at (here) the location "/tmp/data", with the name "alice". The following script creates such a store from a raw text file, which it splits into individual documents by splitting it into paragraphs. #!/usr/bin/python import mgindexer fi = open("alice13a.txt", "rb") fo = open("alice13a.splitted.txt", "wb") for line in fi.readlines(): # split the file on the paragraph boundaries if line.strip() == "": fo.write(mgindexer.SEPARATOR) else: fo.write(line) fo.close() fi.close() mgindexer.makeindex("alice13a.splitted.txt", "/tmp/data/", "alice") If you have many individual documents you would like to run a search on, the following script is probably closer to what you need (notice it creates a new collection of the name "files", so you have to substitute "alice" by "files" in the example query script above): #!/usr/bin/python import mgindexer import os PATH = "files/" fo = open("searchdata.txt", "wb") for file in os.listdir(PATH): if os.path.isfile(PATH + file): # copy file fi = open(PATH + file, "rb") for line in fi.readlines(): fo.write(line) # write document boundary fo.write(mgindexer.SEPARATOR) fo.close() mgindexer.makeindex("searchdata.txt", "/tmp/data", "files") Whats New in This Release: - This release adds support for wildcard search (truncation). - Document types that have delimiters different from whitespace are now supported..

Requirements: No special requirements
Platforms: Linux
Keyword: File Import Libraries Magpy Mg Path Programming Python Search
Users rating: 0/10

License: Freeware Size: 327.68 KB
USER REVIEWS
More Reviews or Write Review


MAGPY RELATED
Programming  -  PATH programming language 0.33
PATH is a very different programming language than what you are probably used to if youre an average programmer. If youve programmed in the language Brainf*ck, youll recognize the memory cell architecture. Also, Befunge programmers will recognize...
10.24 KB  
Libraries  -  File::Basename 5.8.8
File::Basename is a Perl module to parse file paths into directory, filename and suffix. SYNOPSIS use File::Basename; ($name,$path,$suffix) = fileparse($fullname,@suffixlist); $name = fileparse($fullname,@suffixlist); $basename =...
12.2 MB  
Text Management  -  Yet Another Python Templating Utility (YAPTU) 1.5
"Templating" (copying an input file to output, on the fly inserting Python expressions and statements) is a frequent need, and YAPTU is a small but complete Python module for that; expressions and statements are identified by arbitrary user-chosen...
 
Entertainment  -  Radio Nova Fm Divinopolis-MG 1.0
The Radio Nova is a station located in Divinopolis-MG, With programming 100% Sertaneja. Also bringing news Divinopolis Region and on your schedule. Requirements: iOS 4.3 or later. Compatible with iPhone, iPad, and iPod touch. This app...
8.5 MB  
ActiveX Components  -  MinGW 3.4.1
The GNU Compiler Collection (GCC) for Windows MinGW - A collection of freely available and freely distributable Windows specific header files and import libraries combined with GNU toolsets that allow one to produce native Windows programs that do...
15 MB  
Modules  -  Entrez Database Import 6.x-1.0-beta1
This module allows to import PubMed articles by ID and by Search term into the biblio database. Moderated mass retrieval per Batch API and cronjob as well as automatic updates in cron makes it a valuable addition to the biblio module.Built mostly...
30.72 KB  
Modules  -  Advanced cache 1.0
It provides caching nodes, comments, taxonomy (terms, trees, vocabularies and terms-per-node), path aliases, and search results. The module creates dedicated cache tables and makes use of Drupal's core cache API to cache data in an efficient...
 
File Utilities  -  DiskBoss Network 1.8.12
DiskBoss is an automated, rule-based file and disk management solution allowing one to search, classify and categorize files, perform disk space utilization analysis, automatically organize files according to user-defined rules and policies, copy...
 
Reference  -  HBCLibraries 1.0
HBC Libraries Use this app to check if HBC Libraries have a book. You can search in one of three ways - Scan the barcode of an individual book Enter a title (or part of a title) Enter an author name (or part of an author...
614.4 KB  
Travel  -  Flight247 1.0.0.0
[English] Flight247 is an simple tool that helps you track flights around you. The planes location as well as the path it travel. Search by flight number, airport or route. Pin your flight favorite for quick access. Requirements:...
2 MB  
NEW DOWNLOADS IN PROGRAMMING, LIBRARIES
Programming  -  FLEX-db Digital Asset Manager 3.0.9
FLEX-db - an enterprise Digital Asset Manager (DAM). It ingests and links metadata with files, creates thumbnails, and processes files using business rules. FLEX-db has a JSP client, Java app server for file input and output and an EJB metadata...
21.57 MB  
Programming  -  Libicom 0.9.0
The libicom library is a character based dynamicly linked library for Linux. It is used to remotely control the Icom IC-R8500 wide band receiver via an RS232 link. All call and return parameters to the control functions are character string based....
20.48 KB  
Programming  -  dotdesktop 0.3
Dotdesktop library provides ability to parse desktop entry file and access the information in a convenient way. Desktop entry file format is defined by freedesktop.org, it is used to describe information about an application such as the name and...
327.68 KB  
Programming  -  Cedalion for Linux 0.2.6
Cedalion is a programming language that allows its users to add new abstractions and define (and use) internal DSLs. Its innovation is in the fact that it uses projectional editing to allow the new abstractions to have no syntactic limitations.
471.04 KB  
Programming  -  libyasl 0.2
Libyasl is a C++ class library to easily realize TCP/UDP/Multicast clientsand servers in IPv4 and IPv6 environments under GNU/Linux systems.
143.36 KB  
Libraries  -  wolfSSL 3.11.0
The wolfSSL embedded SSL/TLS library is a lightweight SSL library written in ANSI standard C and targeted for embedded and RTOS environments - primarily because of its small size, speed, and feature set. It is commonly used in standard operating...
2.73 MB  
Libraries  -  EuGTK 4.8.9
Makes it easy to develop good- looking, fast, cross-platform programs that run on Linux, OS X, and Windows. Euphoria is a very fast interpreted/compiled language with straight-forward syntax. EuGTK allows programming in a clean, object-oriented...
10.68 MB  
Libraries  -  Linux User Group Library Manager 1.0
The LUG Library Manager is a project to help Linux User Groups start their own library. A LUG library is helpful to the community at large because it increases access to information, and gives everyone the opportunity to become more knowledgeable.
5.35 KB  
Libraries  -  Module::MakefilePL::Parse 0.12
Module::MakefilePL::Parse is a Perl module to parse required modules from Makefile.PL. SYNOPSIS use Module::MakefilePL::Parse; open $fh, Makefile.PL; $parser = Module::MakefilePL::Parse->new( join("", ) ); $info = $parser->required;...
8.19 KB  
Libraries  -  sqlpp 0.06
sqlpp Perl package is a SQL preprocessor. sqlpp is a conventional cpp-alike preprocessor taught to understand SQL ( PgSQL, in particular) syntax specificities. In addition to the standard #define/#ifdef/#else/#endif cohort, provides also...
10.24 KB