Giter VIP home page Giter VIP logo

pfp's People

Contributors

erikfrey avatar nova77 avatar yifanzhang avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

pfp's Issues

whitespace causes segfault

The empty string causes pfp to segfault (either in Python bindings or on the commandline), as does whitespace (\n, \t, ' ', combinations thereof).

make on OS X Snow Leopard 10.6.4

When I run make on OS X Snow Leopard 10.6.4 I get the following error:

/usr/bin/c++   -Dpfp_EXPORTS -DNDEBUG -fPIC -Iwavii-pfp-40d9e5a/include -I/usr/include/python2.6   -Wall -O3 -march=native -mtune=native `getconf LFS_CFLAGS` -o CMakeFiles/pfp.dir/src/pfp/config.o -c wavii-pfp-40d9e5a/src/pfp/config.cpp
getconf: no such configuration parameter `LFS_CFLAGS'
wavii-pfp-40d9e5a/src/pfp/config.cpp:1: error: bad value (native) for -march= switch
make[2]: *** [CMakeFiles/pfp.dir/src/pfp/config.o] Error 1
make[1]: *** [CMakeFiles/pfp.dir/all] Error 2
make: *** [all] Error 2

I use the universal binary for cmake version 2.8.2 for Darwin to generate the Makefiles.

Build issues

test doesn't build. This should fix it:

--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -60,7 +60,7 @@ ELSE(APPLE)
    TARGET_LINK_LIBRARIES(pfpd pfp boost_filesystem boost_thread boost_regex boost_system icuio icuuc)
    TARGET_LINK_LIBRARIES(pfpc pfp boost_filesystem boost_thread boost_regex boost_system icuio icuuc)
    TARGET_LINK_LIBRARIES(pfpc_token pfp boost_filesystem boost_thread boost_regex boost_system icuio icuuc)
-   TARGET_LINK_LIBRARIES(test pfp boost_thread boost_unit_test_framework boost_regex icuio icuuc)
+   TARGET_LINK_LIBRARIES(test pfp boost_filesystem boost_thread boost_unit_test_framework boost_regex boost_system icuio icuuc)
 ENDIF(APPLE)

 INSTALL(TARGETS pfpd DESTINATION bin)

Also, I can't seem to install pfp to anywhere but /usr. When I set -DCMAKE_INSTALL_PREFIX, I get:

Install the project...
/usr/bin/cmake -P cmake_install.cmake
-- Install configuration: ""
-- Installing: /usr/bin/pfpd
CMake Error at cmake_install.cmake:42 (FILE):
  file INSTALL cannot copy file "/tmp/pfp2/pfpd" to "/usr/bin/pfpd".


make: *** [install] Error 1

Build error MacOS - boost

I am trying to build on MacOs 10.10

I installed boost using homebrew.
Using make I get the following error:

/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/c++ -DNDEBUG -Dpfp_EXPORTS -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.10.sdk -fPIC -I/Users/stefan/Code/Brain/pfp/include -I/usr/include/python2.6 -Wall -O3 -o CMakeFiles/pfp.dir/src/pfp/tokenizer.yy.o -c /Users/stefan/Code/Brain/pfp/src/pfp/tokenizer.yy.cpp
In file included from ../etc/tokenizer.flex:5:
/Users/stefan/Code/Brain/pfp/include/pfp/tokenizer.h:7:10: fatal error: 'boost/optional.hpp' file not found

include <boost/optional.hpp>

     ^

1 error generated.

I am not sure, why boost/optional.hpp is not part of the homebrew packet.
What is needed form this packet?

Is there a binary MacOS distribution somewhere with python bindings?

Long sentences throw Aliens error "game over, man!"

Although one can specify a token limit, the parser sometimes runs into problems with longer sentences:

Python 2.6.5 (r265:79063, Apr 16 2010, 13:09:56) 
[GCC 4.4.3] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import pfp
>>> pfp.Parser(200).parse('The report is consistent of two parts in scrutiny level, with one part analysing from the point of view by our survey and views from the user (survey launched marked Heading 2), and with another part analysing from perspective by technical aspect through Achieving Excellence Design Evaluation Toolkit (AEDET Evolution) which is a tool for evaluating the quality of design in healthcare buildings and A Staff and Patient Calibration Toolkit (ASPECT) which is a tool for evaluating the staff and patient environment in healthcare buildings (Heading 3).')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
RuntimeError: game over, man!

Hashes (#) are returned without the tag

For instance:
He is my #1 fan.

Will return:

(ROOT
  (S
    (NP (PRP He))
    (VP (VBZ is) (NP (PRP$ my) (ADJP (# ) (CD 1)) (NN fan)))
    (. .)))

Instead of:

(ROOT
  (S
    (NP (PRP He))
    (VP (VBZ is) (NP (PRP$ my) (ADJP (# #) (CD 1)) (NN fan)))
    (. .)))

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.