Home Home Faculty Home Faculty of Computer Science
Free University of Bozen - Bolzano

Database and Information Systems

ABOUT DIS
Staff
Guests
How to reach us
Open Positions

TEACHING
BSc: DB Stream
MSc: DB Stream

COURSES
Advanced Topics in Databases
Advanced Topics in Inf. Systems
Approximation: Theory and Algorithms
Data Management Systems
Data Structures and Algorithms
Data Warehousing/Mining
Distributed Databases
Mobile Services
Seminar in Databases
Temporal and Spatial Databases

RESEARCH
Publications
PhD Projects
Software
Scientific Services
Seminars

RESEARCH PROJECTS
eBZ – 2015
COSPA
3DVDM-DS
Eurescom P817
Chorochronos
XVDM

FACULTY
IT Services
Faculty Council
Regulations

LINKS
DBLP
OnlineLibraries@unibz
G

W
About
Requirements
Download
Installation
Running
New Module
How Tos
Credits
Links

Adding a New Module into the 3DVDM System

This web pages describes how to add a new module into the 3DVDM system.

0 Step: Download the files.

Download the new_module.tgz (old.tgz) version of the 3DVDM and VR++ systems. This specially prepared version contains a template directory for the new module. Untar and ungzip the files:

   tar xvfz new_module.tgz

The command will create the new_module directory and untar and ungzip the archive files into two subdirectories: 3dvdm-2.3.1 and vr++-0.8.0. Build the the VR++ subsystem:

   cd new_module/vr++
   make
   cd ..

1 Step: Introduce a good name for your module.

Please, introduce a good name of your project. If you are doing Cure clustering a good name for your project could be ``cure''. Avoid too general and indiscriptive names like ``my_module'', or ``classification''. In this document we will be adding a new module called ``example''.

2 Step: Move the template directory.

Move the prepared template directory:

   export PROJECT_NAME="Example"
   export PROJECT_DIR="example"
   cd 3dvdm
   mv new_module $PROJECT_DIR

Please note, that the name of the new directory is the name of your project in lower case characters.

3 Step: Rename the files.

This step renames the template files. We provide specific information what the files contain with this step:

   mv $PROJECT_DIR/include/3dvdm/new_module/ \
     $PROJECT_DIR/include/3dvdm/$PROJECT_DIR/
   mv $PROJECT_DIR/include/3dvdm/$PROJECT_DIR/NewModuleSlave.h \
     $PROJECT_DIR/include/3dvdm/$PROJECT_DIR/$PROJECT_NAME"Slave.h"
   mv $PROJECT_DIR/include/3dvdm/$PROJECT_DIR/NewModuleMapper.h \
     $PROJECT_DIR/include/3dvdm/$PROJECT_DIR/$PROJECT_NAME"Mapper.h"
   mv $PROJECT_DIR/masters/bin-scripts/new_module \
     $PROJECT_DIR/masters/bin-scripts/$PROJECT_DIR
   mv $PROJECT_DIR/masters/lammpi-scripts/new_module \
     $PROJECT_DIR/masters/lammpi-scripts/$PROJECT_DIR
   mv $PROJECT_DIR/masters/NewModuleMaster.cxx \
     $PROJECT_DIR/masters/$PROJECT_NAME"Master.cxx"
   mv $PROJECT_DIR/slaves/NewModuleSlave.cxx \
     $PROJECT_DIR/slaves/$PROJECT_NAME"Slave.cxx"
   mv $PROJECT_DIR/tasks/NewModuleMapper.cc \
     $PROJECT_DIR/tasks/$PROJECT_NAME"Mapper.cc"

Please note the capitalization of the file names.

4 Step: Rename the project name in the files.
   sed -e s/new_module/$PROJECT_DIR/g Makefile > temp && \
     mv temp Makefile
   sed -e s/NewModule/$PROJECT_NAME/g -e s/new_module/$PROJECT_DIR/g \
     $PROJECT_DIR/package.make > temp && \
     mv temp $PROJECT_DIR/package.make
   sed -e s/NewModule/$PROJECT_NAME/g -e s/new_module/$PROJECT_DIR/g \
     $PROJECT_DIR/include/3dvdm/$PROJECT_DIR/$PROJECT_NAME"Mapper.h" \
     > temp && \
     mv temp $PROJECT_DIR/include/3dvdm/$PROJECT_DIR/$PROJECT_NAME"Mapper.h"
   sed -e s/NewModule/$PROJECT_NAME/g -e s/new_module/$PROJECT_DIR/g \
     $PROJECT_DIR/include/3dvdm/$PROJECT_DIR/$PROJECT_NAME"Slave.h" \
     > temp && \
     mv temp  $PROJECT_DIR/include/3dvdm/$PROJECT_DIR/$PROJECT_NAME"Slave.h"
   sed -e s/NewModule/$PROJECT_NAME/g -e s/new_module/$PROJECT_DIR/g \
     $PROJECT_DIR/masters/Makefile > temp && \
     mv temp $PROJECT_DIR/masters/Makefile
   sed -e s/NewModule/$PROJECT_NAME/g -e s/new_module/$PROJECT_DIR/g \
     $PROJECT_DIR/masters/lammpi-scripts/$PROJECT_DIR > temp && \
     mv temp $PROJECT_DIR/masters/lammpi-scripts/$PROJECT_DIR
   sed -e s/NewModule/$PROJECT_NAME/g -e s/new_module/$PROJECT_DIR/g \
     $PROJECT_DIR/masters/$PROJECT_NAME"Master.cxx" > temp && \
     mv temp $PROJECT_DIR/masters/$PROJECT_NAME"Master.cxx"
   sed -e s/NewModule/$PROJECT_NAME/g -e s/new_module/$PROJECT_DIR/g \
     $PROJECT_DIR/slaves/$PROJECT_NAME"Slave.cxx" > temp && \
     mv temp $PROJECT_DIR/slaves/$PROJECT_NAME"Slave.cxx"
   sed -e s/NewModule/$PROJECT_NAME/g -e s/new_module/$PROJECT_DIR/g \
     $PROJECT_DIR/tasks/Makefile > temp && \
     mv temp $PROJECT_DIR/tasks/Makefile
   sed -e s/NewModule/$PROJECT_NAME/g -e s/new_module/$PROJECT_DIR/g \
     $PROJECT_DIR/tasks/$PROJECT_NAME"Mapper.cc" > temp && \
     mv temp $PROJECT_DIR/tasks/$PROJECT_NAME"Mapper.cc"
   sed -e s/NewModule/$PROJECT_NAME/g -e s/new_module/$PROJECT_DIR/g \
     $PROJECT_DIR/masters/bin-scripts/$PROJECT_DIR > temp && \
     mv temp $PROJECT_DIR/masters/bin-scripts/$PROJECT_DIR
   sed -e s/NewModule/$PROJECT_NAME/g -e s/new_module/$PROJECT_DIR/g \
     $PROJECT_DIR/COPYING > temp && mv temp $PROJECT_DIR/COPYING

5 Step: Test the new module.

Build the system:

  make

Test the build system:

  ./bin/$PROJECT_DIR

6 Step: Update the COPYING file.

The COPYING file include the GNU Lesser copyright information, and the contact information of the new module at the bottom. Please edit the file and update your contact information:

  vi $PROJECT_DIR/COPYING