File: wt_ap.cpp

package info (click to toggle)
libsdsl 2.1.1%2Bdfsg-3
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 3,992 kB
  • sloc: cpp: 42,286; makefile: 1,171; ansic: 318; sh: 201; python: 27
file content (24 lines) | stat: -rw-r--r-- 576 bytes parent folder | download | duplicates (17)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#include <sdsl/wavelet_trees.hpp>

using namespace sdsl;
using namespace std;

int main(int argc, char* argv[])
{
    if (argc < 2) {
        return 1;
    }
    wt_ap<> wt;
    memory_monitor::start();
    construct(wt, argv[1], 1);
    memory_monitor::stop();
    {
        std::ofstream csaofs("wt-construction.html");
        cout << "writing memory usage visualization to csa-construction.html\n";
        memory_monitor::write_memory_log<HTML_FORMAT>(csaofs);
    }
    {
        std::ofstream out("wt-space.html");
        write_structure<HTML_FORMAT>(wt,out);
    }
}