Page 2 of 3

Re: important information (Thu 27 Mar 08)

Posted: Sat Mar 29, 2008 2:19 am
by JohnMorris
euler wrote:
markcrim wrote:it seems to me a natural fit would be a university comp sci department.
That would be perfect if we could find one.
Well, there's the PE mailing list and RSS feed which may reach more people than just those who visit this forum. Perhaps an appeal via those channels might find something?
euler wrote: ...7.3% CPU usage; our limit is 4.5%.
If ever there was a place full of people who can get big results from a little CPU usage, PE must be it :-) Have you considered showing the code around to see if anyone can come up with smart optimizations?

Or mirror sites (yes, there's a cost) with hourly or so synchronization?

And of course, if that donate button gets added, count me in.

Re: important information (Thu 27 Mar 08)

Posted: Sat Mar 29, 2008 2:26 am
by JohnMorris
One more thought - maybe this is just dumb, but if you paid them three times the money, would they allow you three times the CPU? Even if only while seeking a new home?

Re: important information (Thu 27 Mar 08)

Posted: Sat Mar 29, 2008 2:25 pm
by unime
0.13 seconds of CPU time per visit seems excessive to me. Can you profile pages to find the bottlenecks? Forums and other database operations are typical culprits.

I have read suggestions that blocking bots (like google) can reduce CPU usage by 50%. Have you tried changing robots.txt?

I am not a fan of javascript heavy pages (call me old school but I think most pages should work without scripting).

Caching the top 1000 and per-user problem pages may reduce load if not already done.

Re: important information (Thu 27 Mar 08)

Posted: Sat Mar 29, 2008 5:55 pm
by Dogun
unime wrote:I am not a fan of javascript heavy pages (call me old school but I think most pages should work without scripting).
Neither am I. A page should render properly if you disable javascript, which is in my opinion the worst thing that ever happened to the web. Unless you happen to /like/ stupid right click disables, infinite rickrolls, etc.

Re: important information (Thu 27 Mar 08)

Posted: Sat Apr 05, 2008 10:26 am
by stijn263
Euler wrote:UPDATE (Fri 04 Apr 08)
To help ease load on the server a decision has been made to lock threads to older problems. For example, the thread for problem 1 contains over nine-hundred posts! If you actually managed to read through the entire thread you would believe that you had just become the main character in a new film, Groundhog Day 2. The intention, over time, is to incorporate an associated "article" system whereby a summary of the problem and some code examples in different language groups will be presented; the archived thread will still remain accessible.
I like the idea of an article system, do you have any idea how you're going to implement it? I think a wiki like system would cause even more server load.

Also I'd vote for removing the square box around a tick, other than that, the new icons (Image) look pretty nice imo.

Re: important information (Thu 27 Mar 08)

Posted: Sat Apr 05, 2008 11:53 am
by euler
The article system will probably involve a link appearing next to the thread link (once a problem has been solved) to a PDF document. The benefit of this is that authors have more control over formatting and it will not be putting additional load on the database.
henk263 wrote:Also I'd vote for removing the square box around a tick, other than that, the new icons (Image) look pretty nice imo.
I'm glad you like them, but I'm certainly no artist. In fact, you've just reminded me to add a comment to the About page to give credit to the icon creator, Mark James: http://www.famfamfam.com/lab/icons/silk/.

What did you mean about the square box?

Re: important information (Thu 27 Mar 08)

Posted: Sat Apr 05, 2008 12:17 pm
by stijn263
Who will make the PDF documents? Or can any solver just submit one? Perhaps the problem proposer is a good candidate (if he wants to, of course).

This is what I meant

Re: important information (Thu 27 Mar 08)

Posted: Sat Apr 05, 2008 12:35 pm
by Tommy137
henk263 wrote:This is what I meant
With IE7 or Mozilla Firefox there aren't any boxes. You're using IE6?

Re: important information (Thu 27 Mar 08)

Posted: Sat Apr 05, 2008 12:38 pm
by euler
I think you're right, Tommy137; they don't appear in any of my test browsers: Firefox (2.0.0.13; my normal browser), IE (7), Opera (9.26), or Safari (3.0.4). But I wonder why the other PNG images with transparency are viewing fine?

[edit]Could you try now, henk263? I think I've just added a JS fix with a conditional load for IE < 7.[/edit]

Re: important information (Thu 27 Mar 08)

Posted: Sat Apr 05, 2008 12:53 pm
by Tommy137
I just tried IE6 and didn't see any boxes.

Re: important information (Thu 27 Mar 08)

Posted: Sat Apr 05, 2008 1:24 pm
by sfabriz
That happens because png support was added just in ie7 while with ff there are no problems. Ie6 doesn't render them well.
If you want everybody to be able to render transparent background image properly, just use .gif.
Another option could be to make white-background .png images (and lightblue too, of course), which you could since there are no rollover rows.

Cheers

Re: important information (Thu 27 Mar 08)

Posted: Sat Apr 05, 2008 1:36 pm
by sfabriz
@staff:

Useful tools to edit/convert/browse images:

http://www.faststone.org/ (this is really cool and totally free)

http://www.irfanview.com/ (free too, has the best save as icon feature I've ever seen on free programs)

Cheers

Re: important information (Thu 27 Mar 08)

Posted: Sat Apr 05, 2008 2:09 pm
by stijn263
euler wrote:Could you try now, henk263? I think I've just added a JS fix with a conditional load for IE < 7
Yup, it's fixed. However, loading the page takes a whole lot longer now. First I briefly see the page with the square boxes, then it gets blank for a while, and finally I see the page without the boxes.

I'm at 100% for allmost a minute when I try to load the problem page..

Re: important information (Thu 27 Mar 08)

Posted: Sat Apr 05, 2008 2:28 pm
by hk
henk263 wrote:Who will make the PDF documents? Or can any solver just submit one? Perhaps the problem proposer is a good candidate (if he wants to, of course).
The article system is still under development.
I for myself do not envision writing articles for recent problems. That would kill the exchange in the forum and would mean endless revisions as new ideas come up there.

The locking of the fora for the older problems has become necessary for the follwing reason:
If you would go to the forum for problem 1 you would see that it now contains 38 pages. 5 of those pages were added during the last month. :shock:
For problem 10 we have 347 posts; 30 of which during the last month.
Most posts are repeating the same inefficient solutions or repeating older posts.

What I'm envisioning is articles for the lower numbered (locked) problems how that problem can be solved efficiently.
And as Colin wrote: some code examples for a group of languages. At the end of such an article would be a link to the cached version of the forum for that problem.
When the article system has been crystallized out we will tell what further plans we have been developing.
I think we could use the help of some of those that have solved (almost) every problem in writing those articles.

Re: important information (Thu 27 Mar 08)

Posted: Sat Apr 05, 2008 2:38 pm
by hk
henk263 wrote:
euler wrote:Could you try now, henk263? I think I've just added a JS fix with a conditional load for IE < 7
Yup, it's fixed. However, loading the page takes a whole lot longer now. First I briefly see the page with the square boxes, then it gets blank for a while, and finally I see the page without the boxes.

I'm at 100% for allmost a minute when I try to load the problem page..
I suppose you are viewing your browser cache. I think updating browser caches allover causes some extra server load.
This morning everything went very slow here. Now it's taking up pace again.

Re: important information (Thu 27 Mar 08)

Posted: Sat Apr 05, 2008 3:43 pm
by stijn263
Hans Klein wrote:And as Colin wrote: some code examples for a group of languages. At the end of such an article would be a link to the cached version of the forum for that problem.
When the article system has been crystallized out we will tell what further plans we have been developing.
Ok, I'll wait and see :) am I right that every topic with over 100 posts has been closed?

I would be glad to help get you C++ and Maple solutions for the locked problems. Would have to make my original code somewhat more readible, but that shouldn't take too long.

Re: important information (Thu 27 Mar 08)

Posted: Sat Apr 05, 2008 5:20 pm
by euler
@sfabriz: I tried converting the images, but they're just not as good (if you look close enough). I tried both programs and although IfanView did a slightly better job neither were really good enough. Here is an image to compare which I've blown up so you can see more clearly what's going on. From left to right: original PNG, IfanView, FastStone, GIMP.
Image
I found that GIMP (although no batch conversion with this) did the best, but it seems we'd be compromising for the sake of an outdated browser.


And here are some interesting statistic for you all regarding the distribution of main browsers that members of Project Euler use:
Firefox = 54.7 %
MS Internet Explorer = 27.4 %
Opera = 6.7 %
Mozilla = 3.3 %
Safari = 3 %

@henk263: Is it still taking a long time to load the page?

Re: important information (Thu 27 Mar 08)

Posted: Sat Apr 05, 2008 5:58 pm
by stijn263
Yup. It seems my cpu has to do a lot of work whenever I am loading the problems page :S

Re: important information (Thu 27 Mar 08)

Posted: Sat Apr 05, 2008 8:04 pm
by euler
I think it'd be better to have slightly noticeable square boxes than that; I've removed the JS fix. Have you thought about using a proper *ahem*, sorry, a different browser?

Re: important information (Thu 27 Mar 08)

Posted: Sun Apr 06, 2008 10:09 pm
by Chris
Hi,

I'm the lead Tech from Project Euler's Hosting provider so I thought I would drop by just to mention a few things, since I am currently moving databases about :) So appologies first of all for some short outages you might see here and there at the moment.

The main problems in terms of server resource usage for the site comes down purley to MySQL. Because of this Project Euler is now running in a mini clustered environment with a Dedicated MySQL machine to handle all of the database requests.

To begin with things may seem to run a little slow, as we can tweak bits here and there after we can see how things are performing under usual load. With this setup we are able to add additional resources such as RAM on the fly with no downtime as we make use of Virtual Machines for applications like this; as well as working out cheaper than a complete semi dedicated or dedicated solution.

So we will have these problems sorted very soon :)

Chris