Install on ubuntu 64bit

Hi,

I would like to use LUI for the visualization but I have some problems with the install.

I am on Ubuntu 20.04.2 LTS, 64-bits (dual-boot).

I started by following the instructions listed here:
http://moin.delph-in.net/wiki/LkbLui#Obtaining_and_Running_LUI

Three different way to activate LUI are proposed:
a. manually within a running LKB session
b. from within the `.lkbrc’ user-specific LKB configuration file
c. by means of a shell environment variable

I tried the (a) and start by the LKB Install
http://moin.delph-in.net/wiki/LkbInstallation

I followed step by step “Automated Installation”

Once the procedure is complete, I add the line

export DELPHINHOME=/home/myname/delphins

at the end of my .bashrc file.

I didn’t have Emacs installed, I installed it but I can’t find the .emacs file.
So I don’t add lines for emacs.

But I have errors with the command:

$DELPHINHOME/bin/lkb

First, I had the error:

Warning: Loading sys:climxm.so failed with error:
libXpm.so.4: cannot open shared object file: No such file or directory.

So I used the solution in “Trouble Shooting” section and now I have another error:

Warning: Loading sys:climxm.so failed with error:
libXt.so.6: cannot open shared object file: No such file or directory.
International Allegro CL Enterprise Edition
8.1 [Linux (x86)] (Oct 27, 2014 14:54)
Copyright © 1985-2007, Franz Inc., Oakland, CA, USA. All Rights Reserved.

This standard runtime copy of Allegro CL was built by:
[TC8776]

An unhandled error occurred during initialization:
Attempt to do an array operation on EXCL::REGISTER-FOREIGN-CALLABLE
which is not an array.

I tried to search ubuntu packages that libXt.so.6 need but after install them, I always have the same error.

It’s specified “for 32-bit Linux on x86” so can I not use that with my 64bits ?
Do you think I have to use emacs ?

Thanks,
Bastien

EDIT:

I finally add lines in .emacs file.
But when I try “alt+x lkb” I have the issue:
emacs
“No file or folder, lkb”

Hi @bastien ,

Before you invest too much more time getting this version of the LKB running, are you quite sure you’ve identified the most appropriate system for your needs? There are several systems that run DELPH-IN grammars, and they are oriented to different kinds of user and task.

You say you want to “use LUI for the visualization” - but what is your ultimate goal? If you want to develop your own, new HPSG grammar then the LKB is appropriate. It is also appropriate if you want to browse an existing grammar and investigate in detail how it works. However, there is a more modern and easy-to-install version of the LKB that would probably suit your needs better: http://moin.delph-in.net/wiki/LkbFos

If you want to parse large text corpora with an existing grammar and associated disambiguation model – but not attempt to modify the grammar – then the ACE system is more appropriate: http://moin.delph-in.net/wiki/AceTop

If you want to parse a small number of sentences with one of the large-scale grammars (ERG/Jacy/Indra/Zhong) and visualize the results, then you don’t need to install any software at all. Instead use the Web demo at http://delph-in.github.io/delphin-viz/demo/

If you’re certain you want to use the version of the LKB you’ve started to install, then read on. Before trying to run the LKB inside emacs, make sure it runs from the unix command line:

$DELPHINHOME/bin/lkb

I’ve just tried installing the LKB on a fresh 64-bit Ubuntu system, and before I could get it running I had to install a few 32-bit libraries:

sudo apt install libc6:i386
sudo apt-get install libxpm4:i386
sudo apt-get install libxext6:i386
sudo apt-get install libxt6:i386
sudo apt-get install libxt6:i386

With these installed, the LKB works and I get the following output:

$ $DELPHINHOME/bin/lkb
International Allegro CL Enterprise Edition
8.1 [Linux (x86)] (Oct 27, 2014 14:54)
Copyright (C) 1985-2007, Franz Inc., Oakland, CA, USA.  All Rights Reserved.

This standard runtime copy of Allegro CL was built by:
   [TC8776] 


[changing package from "COMMON-LISP-USER" to "LKB"]
LKB(1): 

… and a window `Lkb Top’ opens in the middle of the screen.

I hope this advice is useful,

John

First, thanks you John for your complete answer;

You’re right, I will explain the pipeline.

We have a 5000 sentences corpus. Each sentence is transformed into MRS using CSAW.0.9.25 (we prefer using CSAW because long sentences are important and CSAW is more able to parse them than ACE). With CSAW, we’re using the model ww-1214-gp2 and the grammar erg-1214.

After that, we transform MRS to DMRS via pydelphin.

We want to vizualize DMRS graphs like below:

dmrs

So we need a tool able to take DMRS in input and print the previous visualization.

During inspection of delphin-viz I understand that the library d3.js do it.
But is there an other way (other than js-library) to make it ?

Thanks in advance,

Bastien

Hi,

you can use the PyDelphin LaTeX plugin to visualize the DMRS:

https://pypi.org/project/delphin-latex/

It produces nice graphs in latex that you can easily customize.

1 Like

Hello Bastien,

And thanks, Francis, you beat me to it. My response had some more info so I’ll post anyway. Apologies for any overlap.


The LKB will produce DMRS arc diagrams that look like the following:

dmrs

You can also use PyDelphin with the delphin-latex plugin to produce .tex files that you can compile to PDF with LaTeX and tikz-dependency, which look a little closer to the delphin-viz ones:

dmrs2

These are the same as if you’d clicked the “LaTeX” button in delphin-viz, but here’s how you can do it from a Bash terminal:

$ pip install delphin-latex  # assuming you already have pydelphin
$ delphin convert --from X --to dmrs-tikz SOURCE OUTPUT.tex

Above, X is going to be whatever your source format is and SOURCE can be an [incr tsdb()] profile, a file containing serialized representations in format X, or it can be omitted if you’re piping in from ACE directly (with --from=ace).

There is no command-line way to produce SVGs like delphin-viz does, although it wouldn’t be so difficult to implement. The problem is that those SVGs are really intended for display in a browser and may not look the same rendered in, e.g., PDFs.

1 Like

Hi,

Thanks everyone for help.
Now visual tools are clearer to me.

I used PyDelphin with delphin-latex and convert tex files to pdf with pdflatex and all is perfect.

Once again thanks,
Bastien