GithubHelp home page GithubHelp logo

e-n-f / datamaps Goto Github PK

View Code? Open in Web Editor NEW
341.0 341.0 53.0 1.55 MB

Indexes points and lines and generates map tiles to display them

License: BSD 2-Clause "Simplified" License

C 86.82% C++ 13.18%

datamaps's People

Contributors

aaronlidman avatar e-n-f avatar meekohi 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  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  avatar  avatar

datamaps's Issues

License and version

Hi Eric
We've written a specfile for datamaps to aid in our deployment on Centos and Fedora based machines and it'd be handy if we could assign values for license and version number to it. We'd be happy to submit the specfile for inclusion via a PR too.

Thank you for your time.

Tile count estimate

I was generating a tileset for a single zoom level (15) and actually ran out of inodes!

Command: enumerate -z15 -Z15 dirname | xargs -L1 -P8 ./render -o tiles/dirname

To ensure the machine I'm using is suitable, how can I figure out the total file count (not size) for zoom level 15?

Error on Mavericks

When compiling render:

undef: ___sincos_stret
Undefined symbols for architecture x86_64:

The solution was to run xcode-select --install which I found here: Homebrew/legacy-homebrew#22553

I'm only using the xcode CLI tools, maybe that's it?

Time based colouring

Hey @ericfischer - assume that for each data point, I have a percentage for how far into the day it occurred. What could I feed into the encode script to have it consider this for colouring? I'd like to end up with something where I can see that data points within a certain geographic area happened early in the day, whereas data points within another area happened later into the day. Ideas are appreciated, thank you!

Add readme instructions for stitching tilesets

After a tileset has been created with enumerate and render could you add instructions for some next steps? e.g. how could one stitch/combine all the individual tiles to form one large image?

Area documentation

The docs state

-p area
Specifies a multiplier for dot sizes. Point brightness is automatically reduced by the same factor so the total brightness remains constant, just diffused. The default is 1.
-p garea
Specifies a Gaussian brush instead of a flat disk, as well as a multiplier for dot sizes.

Because both are -p, it's not particularly clear how to specify a Gaussian brush.

Option to splat points with transparency

I've been trying to approximately reproduce a vector-based map I created. In the original, I splat dots at 40% opacity, and with color based on a timestamp:

screenshot 2014-06-30 10 35 08

Alas, we're working with millions of points now and the svg approach has become unscalable, so I am looking toward raster solutions and found this repo (which is amazing, by the way). It'd be great to have the ability to splat points with a specified alpha in datamaps -- but looking through the code I'm not really sure where to start. I've tried some post-processing approaches, but can't find a good mapping from color to alpha. For the best so far I've had to resort to single color and mapping greyscale directly to alpha, which leaves large square grey regions around each point:

screenshot 2014-06-30 17 15 00

Thoughts?

need render-vector documentation

I see that render-vector is a task in the Makefile, but when I add it to the all task, I get an error. Probably because I don't have all the TM2 dependencies installed - but not sure which ones.

On a related note - a million thanks for open-sourcing your secret sauce. This is a really cool piece of code.

Completion of error handling

I have looked at a few source files for your current software. I have noticed that some checks for return codes are missing.

Would you like to add more error handling for return values from functions like the following?

[Question] Readme lacking information?

EDIT: Please delete the question. I just had to do "make" to compile everything using the makefile.

ORIGINAL:

I have almost no knowledge of C at all , and I am trying to follow the Readme in order to make a map as cool as yours.

so right now, i've followed these steps:

1.clone this repo
git clone https://github.com/ericfischer/datamaps.git
2.
cd datamaps

  1. mkdir output_folder

  2. copy in the /datamaps folder a txt file following this structure:

    lat,lon
    lat,lon
    lat,lon
    ...

    cat file.txt | ./encode -o output_folder -z 16

however, i get the following error.

-bash: ./encode: No such file or directory

I guessed it is because encode.c is not compiled.

Then I tried compiling it doing:
gcc encode.c -o encode

and that throws another error:

/tmp/ccTwkJ7r.o: In function `read_file':
encode.c:(.text+0x589): undefined reference to `latlon2tile'
encode.c:(.text+0x750): undefined reference to `bytesfor'
encode.c:(.text+0x822): undefined reference to `xy2buf'
encode.c:(.text+0x87a): undefined reference to `xy2buf'
encode.c:(.text+0x8df): undefined reference to `meta2buf'
/tmp/ccTwkJ7r.o: In function `main':
encode.c:(.text+0x12c1): undefined reference to `bytesfor'
encode.c:(.text+0x12d3): undefined reference to `gSortBytes'
encode.c:(.text+0x163d): undefined reference to `bufcmp'
collect2: error: ld returned 1 exit status

Any help on what I am doing wrong and how to make the maps would help me a lot!

Enumerate a single zoom level?

Any way of enumerating over just a single zoom level? I'm just doing slight brightness and base changes on each zoom level manually to get more control than ramp allows.

Right now I'm just enumerating through everything up to a zoom level and then throwing away everything I don't need, which is wasteful and slow.

merging input data to index

It's not clear in the documentation if the encode tool will merge data to the index if a call it pointing to an existing index. Is that the case?

I tried to read the source code, but I guess my C skills are a little bit rusty.

Thanks for the great project.

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.