Perl 6 - the future is here, just unevenly distributed

IRC log for #pdl, 2014-05-14

| Channels | #pdl index | Today | | Search | Google Search | Plain-Text | summary

All times shown according to UTC.

Time Nick Message
13:39 mohawk joined #pdl
14:28 gtodd joined #pdl
14:47 rindolf joined #pdl
15:26 run4flat joined #pdl
15:27 run4flat o/
15:27 mohawk hello
15:28 rindolf run4flat: hi.
15:28 mohawk what brings you to speak up on "the silent channel"?
15:28 run4flat I've been gone since January, but now I'm back
15:28 run4flat so I thought I'd say "hi"
15:28 run4flat it wasn't so silent back at the start of the year
15:29 run4flat mohawk, you're a new nick to me. Glad to see so many people idling on #pdl
15:29 run4flat :-)
15:31 mohawk i'm a keen guy who's looking to improve PDL's build system
15:32 run4flat ah, fantastic
15:32 mohawk mainly in the field of a) simplification; and b) specifically in making other modules' use of PDL in XS much easier, starting with their Makefile.PL
15:32 mohawk i have a vision
15:32 mohawk already got some changes accepted in Inline and ExtUtils::Depends
15:33 mohawk now furthering those, and moving onto Alien::Base and PDL
15:33 run4flat very nice
15:33 mohawk you're very kind
15:33 mohawk welcome back, anyway - doing anything interesting while away?
15:33 run4flat that's the currency around here. :-)
15:34 run4flat not much for most of the time between January and now, but I have made some interesting progress on TinyCC
15:34 run4flat that is, in the last few weeks
15:34 run4flat It's not quite ripe enough to announce, but it's close
15:35 mohawk announce it anyway
15:35 mohawk get some alpha testers
15:35 run4flat hah
15:35 mohawk release early, release often
15:36 run4flat I'm afraid the alpha testers would probably say, "yep, it still segfaults"
15:36 run4flat Once I have something that sorta kinda runs, I'll reach out to a few people and inquire about the API
15:36 mohawk a thing i've found with gimp-perl is that the moment other people use my code, i get unexpected cases which help me
15:36 mohawk just sayin'
15:36 mohawk (segfault = core dump and stack trace? yes please!)
15:37 run4flat the problem is that I need to dig deeply into the internals of the Tiny C Compiler to understand its assumptions about symbol tables
15:37 run4flat I don't know that many others have the tuits to dig into that
15:38 mohawk fair enough
15:38 mohawk not suggesting they dig into it with you, just that they could provide extra use cases
15:38 run4flat My approach to releases is different from "early and often." I'd rather have "Few but ripe," as Gauss put it
15:39 run4flat Anyway, if things progress smoothly, I'll eventually roll a PDL jit-compiler with it.
15:39 run4flat and that I expect will be much more of a group effort, in line with the PDL3 work
15:39 run4flat which I have yet to look at closely
15:39 run4flat :-(
15:40 mohawk my impression (possibly wrong) is PDL3 is still a bit nebulous
15:40 mohawk small, buildable components are surely the way forward
15:40 mohawk any way to break the TinyCC thing apart?
15:41 run4flat err... kinda, not really
15:41 mohawk awww
15:41 run4flat TinyCC itself is a stand-alone C project
15:41 run4flat not mine
15:42 run4flat I'm working on ripping out the symbol table handling
15:42 mohawk ah HA
15:42 mohawk so component-ising it?
15:43 run4flat the gist of my work with it is this: I want to be able to create many compiler states using libtcc, and share the symbol tables between them
15:43 run4flat this way, I can compile (say) perl.h *once*
15:44 run4flat Any later code that needs to know the calling signature of newSV can simply inquire into the previous context's symbol table
15:45 run4flat so, to answer your question, I'm trying to trick tcc into doing something it wasn't designed to do
15:45 run4flat I am not interested in component-ising the project any more than it already is; it's too large and complicated for that
15:45 mohawk fair enough
15:47 run4flat Right now I'm stuck between writing and extended symbol table API for libtcc, and using the extended symbol table API in an XS module
15:48 run4flat know anybody who would be interested in helping with that? :-)
15:48 run4flat (sorry, ... writing *an extended...)
15:50 run4flat alright, off to lunch
15:50 run4flat o/
15:51 mohawk bon appetit!
15:51 mohawk sounds like an Alien::* related thing
15:52 mohawk i suspect sivoais would have some interesting insights on that, he did some great stuff with Leptonica recently
17:12 mohawk joined #pdl
22:10 sivoais My work is not done! I'm getting somewhere with the docs though.
22:10 mohawk woo hoo!
22:10 mohawk on Image::L?
22:10 sivoais yeah, I've extracted all the doc comments from the C files and have a data structure. Now to spit out POD. :-P
22:12 mohawk nice
22:12 mohawk this is all done automatically?
22:13 sivoais yes. It's a bit slow though because of the way I stored the data in a database.
22:15 sivoais and by slow, I mean it takes about a minute to run :-P
22:20 mohawk ha ha
22:20 mohawk in a database, what kind?
22:21 sivoais SQLite. My go-to for quick-and-dirty analysis.
22:26 sivoais I run ctags on the source and extract the location of all comments. Then I get all comments that occur right before a function definition.
22:27 sivoais It's a bit roundabout, but I wanted to see if I could do it this way.
22:29 mohawk no girly regex for you, then?
22:31 sivoais well, everything here is a regex at the bottom-most layer. :-P ctags uses regex... the comment extract is from Regexp::Common
22:31 sivoais *extraction
22:32 sivoais I mainly wanted to go with a DB because I think that could be used to make a nice IDE-like tool.
22:33 sivoais One of my first ever big projects was trying to get information out of Java classes so I could build code completion for Vim, but I didn't known anything about grammars or DBs back then.
22:34 sivoais scratch that last bit... I knew how to read grammars, but not how to implement them
22:36 mohawk ha
22:37 mohawk sounds like a big solution to a relatively small problem
22:37 mohawk i remember a mentor telling me back in the day that it was a sign of error if one's first go-to thought is a database
22:42 sivoais this is true. I only did it this way as a learning experience. And I learned that the simple schema I used isn't good enough for code. :-)
22:43 mohawk ha ha
22:44 mohawk well, may i suggest not using any more time on it?
22:44 mohawk surely all you're going to do is hold it in memory till you can output as POD?
22:46 sivoais oh, I'm done with that bit. That's for another project I'm going to ramp up on later.
22:47 mohawk grin
22:47 sivoais My plan is to release another version of Image::Leptonica with docs by the end of the week :-)
22:49 mohawk outstanding!
22:50 mohawk is it OO, or (ptoo) procedural?
22:52 sivoais procedural for now, but I have some ideas for making an OO wrapper. Many of the functions have similar inputs -> outputs mappings
22:55 sivoais oooh, I'm also working on a module I call Data::TestImage. It'll have the common test images that are used for demoing image processing algorithms
22:56 mohawk that feels a bit wrong
22:57 mohawk sounds more like an image-processing harness (which may well have such images)
22:57 sivoais don't distribute data using CPAN?
22:57 sivoais ah
22:57 mohawk well, that's a start ;)
22:57 sivoais you mean the name
22:57 mohawk i mean the concept
22:57 mohawk but yes, please don't use CPAN for test images
22:58 mohawk the name says to me it handles data in a test-image type way
22:58 sivoais ok, I see what you mean
22:59 sivoais My reasoning for making it a package is that it would be like MATLAB. They have a way to load test images which makes for good example code.
23:01 sivoais I could use the same approach as Alien::Base and download the data from elsewhere at install time.
23:02 mohawk if you're interested in my opinion here - no
23:02 mohawk put it/them on CIAN instead
23:03 sivoais hehe
23:05 sivoais another way is to just store it at a git repo. cpanm can be pointed at git repo and it'll install it from there
23:06 mohawk why does cpan need to be involved?
23:06 mohawk there may well be a good reason, i just don't see it
23:06 mohawk wget http://website/images.zip
23:07 sivoais It doesn't have to be on cpan. <https://github.com/miyagawa/cpanminus> can install packages from a git repo
23:08 sivoais yeah, that can be done, but I want something like TestImage->get_image_path( 'cameraman.tiff' ) to just work
23:09 sivoais MATLAB is the standard for image processing tools and there all you have to do is
23:09 sivoais I = imread('cameraman'); imshow( I );
23:09 sivoais and you've got a picture on your screen
23:10 sivoais not saying it is a good standard, but it's decent for what it does :-P
23:10 sivoais But this doesn't have to be on CPAN --- it can be installed in other ways
23:11 mohawk use LWP::Simple; $image = get 'http://...';
23:12 mohawk you could make a wafer-thin module that exports imread() and imshow() - one uses LWP::Simple, the other Gtk2
23:13 mohawk (and imread has hardcoded the relevant URL, maybe with a cache)
23:13 mohawk in fact definitely with a cache
23:13 mohawk wouldn't want to destroy the net ;)
23:20 sivoais Ah, OK. Best case would be: host the files somewhere. Have the basic version which just pulls from the URLs and caches. Also have a dummy version (::Full) that forces all of them into the cache for people that want complete offline access.
23:21 mohawk you know what - if you're providing actual code, go ahead and stick the images as well
23:21 mohawk no point in hammering the net for no reason, and cache locations could be hard too
23:21 mohawk i withdraw my objection ;)
23:22 sivoais Actually caching isn't bad at all. I could just use File::ShareDir like Alien::Base does
23:26 mohawk no, i think so long as there's code, you should go with the original plan
23:29 sivoais ok, that's the simplest then. I'm excited about the docs that would come out of this.
23:29 sivoais I basically want something like <http://www.mathworks.com/he​lp/images/ref/bwmorph.html>
23:30 mohawk yeah, groovy
23:40 sivoais <https://github.com/blog/1840-​improving-github-for-science>

| Channels | #pdl index | Today | | Search | Google Search | Plain-Text | summary