|
Thread Rules 1. This is not a "do my homework for me" thread. If you have specific questions, ask, but don't post an assignment or homework problem and expect an exact solution. 2. No recruiting for your cockamamie projects (you won't replace facebook with 3 dudes you found on the internet and $20) 3. If you can't articulate why a language is bad, don't start slinging shit about it. Just remember that nothing is worse than making CSS IE6 compatible. 4. Use [code] tags to format code blocks. |
On February 08 2014 02:39 BisuDagger wrote: Every time I see this thread title I think we should put a project on SVN and give everyone access. Then we can all just jump in and add to the game whenever we have free time. C++ of course (my preference) and built from the ground up. I'd totally put together a frame for a game to jump start this.
Yeah, I'm down. We can collaborate on #tl.code.
I haven't done game dev for some time, but I can help with the lower level modules.
|
Bisutopia19299 Posts
On February 08 2014 02:47 RoyGBiv_13 wrote:Show nested quote +On February 08 2014 02:39 BisuDagger wrote: Every time I see this thread title I think we should put a project on SVN and give everyone access. Then we can all just jump in and add to the game whenever we have free time. C++ of course (my preference) and built from the ground up. I'd totally put together a frame for a game to jump start this. Yeah, I'm down. We can collaborate on #tl.code. I haven't done game dev for some time, but I can help with the lower level modules. I think I'm going to follow through with this over the next week or two I'll put something together. The simplest style for an open source game is to make it open world. So i'll create a basic open world with directX graphics and setup a camera. From there anyone can literally add whatever the want to it. Physics, graphics, sound, a roaming dragon, anything lol. I'll give updates once I can open this to TL.
|
On February 07 2014 23:07 Zocat wrote:Show nested quote +On February 07 2014 22:21 Manit0u wrote:On February 07 2014 12:22 Sub40APM wrote: Hey guys: I am trying to do a quick analysis in pandas. Its that Kaggle question, how to predict if you live or die in the Titanic sinking. So here are the steps I took: import data into a data frame scan data frame for gender and class if gender is female and class is 1 and 2, survived if gender is female and class is 3, 50/50 chance using randomint to see if you survive or not if male, dead.
survived/dead is 1/0. Prior to the scan I create an empty dictionary, the key is each individual's Id and the value is the 1/0 that I add in after the scan through. Seems reasonable? Seems fine. Although I'd possibly add more randomness to it by shuffling the array before selecting a random entry from it (to simulate the chaos of people rushing to the lifeboats while being at different locations of the ship). + Show Spoiler +Just one more easy step and it adds a whole new dimension: srand((unsigned int) time(0)); // generate random seed
mixed arr[] = { stuff, goes, here, ... }; int n = sizeof(arr);
for (int i = 0; i < n; i += 1) { int s = random(n); mixed tmp = arr[i];
arr[i] = arr[s]; arr[s] = tmp; }
Can you explain that? Assuming an uniform distribution (off the PRNG) shuffling the array before selecting a random entry shouldn't add any randomness.
Run it both ways and see if there's any difference or not. You can also generate new random seed every time you invoke the random function.
|
On February 08 2014 05:55 Manit0u wrote:Show nested quote +On February 07 2014 23:07 Zocat wrote:On February 07 2014 22:21 Manit0u wrote:On February 07 2014 12:22 Sub40APM wrote: Hey guys: I am trying to do a quick analysis in pandas. Its that Kaggle question, how to predict if you live or die in the Titanic sinking. So here are the steps I took: import data into a data frame scan data frame for gender and class if gender is female and class is 1 and 2, survived if gender is female and class is 3, 50/50 chance using randomint to see if you survive or not if male, dead.
survived/dead is 1/0. Prior to the scan I create an empty dictionary, the key is each individual's Id and the value is the 1/0 that I add in after the scan through. Seems reasonable? Seems fine. Although I'd possibly add more randomness to it by shuffling the array before selecting a random entry from it (to simulate the chaos of people rushing to the lifeboats while being at different locations of the ship). + Show Spoiler +Just one more easy step and it adds a whole new dimension: srand((unsigned int) time(0)); // generate random seed
mixed arr[] = { stuff, goes, here, ... }; int n = sizeof(arr);
for (int i = 0; i < n; i += 1) { int s = random(n); mixed tmp = arr[i];
arr[i] = arr[s]; arr[s] = tmp; }
Can you explain that? Assuming an uniform distribution (off the PRNG) shuffling the array before selecting a random entry shouldn't add any randomness. Run it both ways and see if there's any difference or not. You can also generate new random seed every time you invoke the random function.
No. If your shuffle wasn't broken all this would do is waste CPU cycles, with the code you've given it would actually bias the results. Re-seeding the RNG everytime you invoke would most likely (depending on the RNG implementation and how you call it) make things much worse.
|
On February 08 2014 05:55 Manit0u wrote:Show nested quote +On February 07 2014 23:07 Zocat wrote:On February 07 2014 22:21 Manit0u wrote:On February 07 2014 12:22 Sub40APM wrote: Hey guys: I am trying to do a quick analysis in pandas. Its that Kaggle question, how to predict if you live or die in the Titanic sinking. So here are the steps I took: import data into a data frame scan data frame for gender and class if gender is female and class is 1 and 2, survived if gender is female and class is 3, 50/50 chance using randomint to see if you survive or not if male, dead.
survived/dead is 1/0. Prior to the scan I create an empty dictionary, the key is each individual's Id and the value is the 1/0 that I add in after the scan through. Seems reasonable? Seems fine. Although I'd possibly add more randomness to it by shuffling the array before selecting a random entry from it (to simulate the chaos of people rushing to the lifeboats while being at different locations of the ship). + Show Spoiler +Just one more easy step and it adds a whole new dimension: srand((unsigned int) time(0)); // generate random seed
mixed arr[] = { stuff, goes, here, ... }; int n = sizeof(arr);
for (int i = 0; i < n; i += 1) { int s = random(n); mixed tmp = arr[i];
arr[i] = arr[s]; arr[s] = tmp; }
Can you explain that? Assuming an uniform distribution (off the PRNG) shuffling the array before selecting a random entry shouldn't add any randomness. Run it both ways and see if there's any difference or not. You can also generate new random seed every time you invoke the random function. That is not explanation, because on the first glance your advice goes against the nature of randomness and probability. If you use random picking from the set, random shuffling beforehand should have absolutely no effect on the "randomness" of the process.
|
Quick question on C++, is this link a good place to learn C++ basics from? Also, how transferable are my skills from Java and Objective-C for C++? I've used a little bit of basic C, too - stdlib.h (realloc, memset, malloc, free, exit), stdio.h, string.h and math.h.
|
For work I had to write a full fledged non-linear regression package in PL\SQL, complete with noise reduction algorithms to make the regression 'robust' (insensitive to structured error found in the data sets we were concerned with). I ended up going with a kind of projected gradient levenberg-merquandt iteratively re-weighted least squares approach. I have a degree in math, but I encountered all sorts of strange numerical analysis challenges that I had never seen before, such as situations where the hessian of the LS objective function was "almost" rank degenerate due to idiosyncracies in the data types in pl\sql, and bizarre issues arising from domain restrictions on the objective function.
Overall, I have learned that I really, really hate programming anything related to math without functional programming tools such as first class functions Also , pl\sql is really not well suited for this kind of high level math, at all. The fun part was that I got to read lots of nifty math papers, and I really love math so it was nice to get to spend my work days on this challenge. The end result was surprisingly fast, but probably wouldn't scale well to extremely large problems (not that it matters for what we're using it for).
|
On February 08 2014 12:59 Fission wrote:For work I had to write a full fledged non-linear regression package in PL\SQL, complete with noise reduction algorithms to make the regression 'robust' (insensitive to structured error found in the data sets we were concerned with). I ended up going with a kind of projected gradient levenberg-merquandt iteratively re-weighted least squares approach. I have a degree in math, but I encountered all sorts of strange numerical analysis challenges that I had never seen before, such as situations where the hessian of the LS objective function was "almost" rank degenerate due to idiosyncracies in the data types in pl\sql, and bizarre issues arising from domain restrictions on the objective function. Overall, I have learned that I really, really hate programming anything related to math without functional programming tools such as first class functions  Also , pl\sql is really not well suited for this kind of high level math, at all. The fun part was that I got to read lots of nifty math papers, and I really love math so it was nice to get to spend my work days on this challenge. The end result was surprisingly fast, but probably wouldn't scale well to extremely large problems (not that it matters for what we're using it for).
could you have applied some scaling to your problem to make the hessian play nice, or am i missing the mark? i got checking out functional programming (through boost phoenix) on my todo list...
|
On February 08 2014 13:35 nunez wrote:Show nested quote +On February 08 2014 12:59 Fission wrote:For work I had to write a full fledged non-linear regression package in PL\SQL, complete with noise reduction algorithms to make the regression 'robust' (insensitive to structured error found in the data sets we were concerned with). I ended up going with a kind of projected gradient levenberg-merquandt iteratively re-weighted least squares approach. I have a degree in math, but I encountered all sorts of strange numerical analysis challenges that I had never seen before, such as situations where the hessian of the LS objective function was "almost" rank degenerate due to idiosyncracies in the data types in pl\sql, and bizarre issues arising from domain restrictions on the objective function. Overall, I have learned that I really, really hate programming anything related to math without functional programming tools such as first class functions  Also , pl\sql is really not well suited for this kind of high level math, at all. The fun part was that I got to read lots of nifty math papers, and I really love math so it was nice to get to spend my work days on this challenge. The end result was surprisingly fast, but probably wouldn't scale well to extremely large problems (not that it matters for what we're using it for). could you have applied some scaling to your problem to make the hessian play nice, or am i missing the mark? i got checking out functional programming (through boost phoenix) on my todo list...
You're on the mark - that's kinda what I did in the end The problem turned out to be that the domain onto which I was projecting the next iteration of the parameter vector was too close to the domain on which the objective function was defined (like, basically coinciding with the boundary), and it was causing the hessian of the objective function to have values really close to zero in it, which, when inverted, was causing an overflow. The fix was to ensure that there was enough "room" on the domain of the parameter space to make sure that little nudges in any direction wouldn't cause anything to break. Sorry if this is unclear :S
|
On February 08 2014 03:45 BisuDagger wrote:Show nested quote +On February 08 2014 02:47 RoyGBiv_13 wrote:On February 08 2014 02:39 BisuDagger wrote: Every time I see this thread title I think we should put a project on SVN and give everyone access. Then we can all just jump in and add to the game whenever we have free time. C++ of course (my preference) and built from the ground up. I'd totally put together a frame for a game to jump start this. Yeah, I'm down. We can collaborate on #tl.code. I haven't done game dev for some time, but I can help with the lower level modules. I think I'm going to follow through with this over the next week or two I'll put something together. The simplest style for an open source game is to make it open world. So i'll create a basic open world with directX graphics and setup a camera. From there anyone can literally add whatever the want to it. Physics, graphics, sound, a roaming dragon, anything lol. I'll give updates once I can open this to TL. Just curious, why no opengl for linux/mac? Do you intend to use OS specific functionality (or keep that option open), hence directx over opengl?
|
@fission ah, neat.
@rollin i am curious too.
|
On February 08 2014 07:39 mcc wrote:Show nested quote +On February 08 2014 05:55 Manit0u wrote:On February 07 2014 23:07 Zocat wrote:On February 07 2014 22:21 Manit0u wrote:On February 07 2014 12:22 Sub40APM wrote: Hey guys: I am trying to do a quick analysis in pandas. Its that Kaggle question, how to predict if you live or die in the Titanic sinking. So here are the steps I took: import data into a data frame scan data frame for gender and class if gender is female and class is 1 and 2, survived if gender is female and class is 3, 50/50 chance using randomint to see if you survive or not if male, dead.
survived/dead is 1/0. Prior to the scan I create an empty dictionary, the key is each individual's Id and the value is the 1/0 that I add in after the scan through. Seems reasonable? Seems fine. Although I'd possibly add more randomness to it by shuffling the array before selecting a random entry from it (to simulate the chaos of people rushing to the lifeboats while being at different locations of the ship). + Show Spoiler +Just one more easy step and it adds a whole new dimension: srand((unsigned int) time(0)); // generate random seed
mixed arr[] = { stuff, goes, here, ... }; int n = sizeof(arr);
for (int i = 0; i < n; i += 1) { int s = random(n); mixed tmp = arr[i];
arr[i] = arr[s]; arr[s] = tmp; }
Can you explain that? Assuming an uniform distribution (off the PRNG) shuffling the array before selecting a random entry shouldn't add any randomness. Run it both ways and see if there's any difference or not. You can also generate new random seed every time you invoke the random function. That is not explanation, because on the first glance your advice goes against the nature of randomness and probability. If you use random picking from the set, random shuffling beforehand should have absolutely no effect on the "randomness" of the process.
It depends on what you want in the end. If you want for your random pick from the set always producing the same result or not (ie: you run your test twice, both times you get 5 or whatever on your RNG, if you won't shuffle the set, the outcome will be the same each time). Shuffling the set makes it much less likely to get the same results after multiple passes. I agree that generating random seed each time is an overkill though.
|
On February 08 2014 03:45 BisuDagger wrote:Show nested quote +On February 08 2014 02:47 RoyGBiv_13 wrote:On February 08 2014 02:39 BisuDagger wrote: Every time I see this thread title I think we should put a project on SVN and give everyone access. Then we can all just jump in and add to the game whenever we have free time. C++ of course (my preference) and built from the ground up. I'd totally put together a frame for a game to jump start this. Yeah, I'm down. We can collaborate on #tl.code. I haven't done game dev for some time, but I can help with the lower level modules. I think I'm going to follow through with this over the next week or two I'll put something together. The simplest style for an open source game is to make it open world. So i'll create a basic open world with directX graphics and setup a camera. From there anyone can literally add whatever the want to it. Physics, graphics, sound, a roaming dragon, anything lol. I'll give updates once I can open this to TL.
I would be down on this. Maybe I can finally dev something up for my oculus rift  Git/Hg over Svn plz
|
On February 08 2014 18:47 Manit0u wrote:Show nested quote +On February 08 2014 07:39 mcc wrote:On February 08 2014 05:55 Manit0u wrote:On February 07 2014 23:07 Zocat wrote:On February 07 2014 22:21 Manit0u wrote:On February 07 2014 12:22 Sub40APM wrote: Hey guys: I am trying to do a quick analysis in pandas. Its that Kaggle question, how to predict if you live or die in the Titanic sinking. So here are the steps I took: import data into a data frame scan data frame for gender and class if gender is female and class is 1 and 2, survived if gender is female and class is 3, 50/50 chance using randomint to see if you survive or not if male, dead.
survived/dead is 1/0. Prior to the scan I create an empty dictionary, the key is each individual's Id and the value is the 1/0 that I add in after the scan through. Seems reasonable? Seems fine. Although I'd possibly add more randomness to it by shuffling the array before selecting a random entry from it (to simulate the chaos of people rushing to the lifeboats while being at different locations of the ship). + Show Spoiler +Just one more easy step and it adds a whole new dimension: srand((unsigned int) time(0)); // generate random seed
mixed arr[] = { stuff, goes, here, ... }; int n = sizeof(arr);
for (int i = 0; i < n; i += 1) { int s = random(n); mixed tmp = arr[i];
arr[i] = arr[s]; arr[s] = tmp; }
Can you explain that? Assuming an uniform distribution (off the PRNG) shuffling the array before selecting a random entry shouldn't add any randomness. Run it both ways and see if there's any difference or not. You can also generate new random seed every time you invoke the random function. That is not explanation, because on the first glance your advice goes against the nature of randomness and probability. If you use random picking from the set, random shuffling beforehand should have absolutely no effect on the "randomness" of the process. It depends on what you want in the end. If you want for your random pick from the set always producing the same result or not (ie: you run your test twice, both times you get 5 or whatever on your RNG, if you won't shuffle the set, the outcome will be the same each time). Shuffling the set makes it much less likely to get the same results after multiple passes. I agree that generating random seed each time is an overkill though. Ah you meant kind of meta-randomness. If that is the goal I think shuffling is still kind of useless, especially since if you just shuffle with the same seed you will still get the same outcome. Just generate new seed before each run and that should be it, no need for shuffling.
|
Bisutopia19299 Posts
On February 08 2014 14:16 Rollin wrote:Show nested quote +On February 08 2014 03:45 BisuDagger wrote:On February 08 2014 02:47 RoyGBiv_13 wrote:On February 08 2014 02:39 BisuDagger wrote: Every time I see this thread title I think we should put a project on SVN and give everyone access. Then we can all just jump in and add to the game whenever we have free time. C++ of course (my preference) and built from the ground up. I'd totally put together a frame for a game to jump start this. Yeah, I'm down. We can collaborate on #tl.code. I haven't done game dev for some time, but I can help with the lower level modules. I think I'm going to follow through with this over the next week or two I'll put something together. The simplest style for an open source game is to make it open world. So i'll create a basic open world with directX graphics and setup a camera. From there anyone can literally add whatever the want to it. Physics, graphics, sound, a roaming dragon, anything lol. I'll give updates once I can open this to TL. Just curious, why no opengl for linux/mac? Do you intend to use OS specific functionality (or keep that option open), hence directx over opengl? DirectX is way more friendly for newer people imo. I don't want to spend time developing ogl tools.
|
And why is it exactly that DirectX is more friendly? I use DX myself but I'd love to hear some arguments because that sounds a little absurd.
|
Hyrule19167 Posts
|
Haha, what a great read. I had no idea about this stuff. Thanks
|
On February 09 2014 00:55 BisuDagger wrote:Show nested quote +On February 08 2014 14:16 Rollin wrote:On February 08 2014 03:45 BisuDagger wrote:On February 08 2014 02:47 RoyGBiv_13 wrote:On February 08 2014 02:39 BisuDagger wrote: Every time I see this thread title I think we should put a project on SVN and give everyone access. Then we can all just jump in and add to the game whenever we have free time. C++ of course (my preference) and built from the ground up. I'd totally put together a frame for a game to jump start this. Yeah, I'm down. We can collaborate on #tl.code. I haven't done game dev for some time, but I can help with the lower level modules. I think I'm going to follow through with this over the next week or two I'll put something together. The simplest style for an open source game is to make it open world. So i'll create a basic open world with directX graphics and setup a camera. From there anyone can literally add whatever the want to it. Physics, graphics, sound, a roaming dragon, anything lol. I'll give updates once I can open this to TL. Just curious, why no opengl for linux/mac? Do you intend to use OS specific functionality (or keep that option open), hence directx over opengl? DirectX is way more friendly for newer people imo. I don't want to spend time developing ogl tools. 
For a collaborate project like this I would highly recommend that you use open standards and not proprietary stuff like DirectX. If you don't you make the project X86, Windows-only excluding people using Mac or Linux. Also, if you want to run it on any non-windows platform you will not be able to unless you go for OpenGL.
Projects and products based on open standards are inherently superior to single platform proprietary crap from Microsoft.
The only place where Microsoft is still relevant is the Desktop, but tablets, chromebooks and similar devices will start eating into their 90% market share pretty soon.
I believe that learning OpenGL is a superior choice for young people interested in making games.
You should check out the SteamOS project from valve and try to do something cool with that.
|
Bisutopia19299 Posts
I hear your points. As a games developer Windows has always been first choice as a the platform for development. I understand Linux has become far more popular over the past few years and if the belief is I'll be isolating a lot of interested developers on teamliquid then I will have no choice but to use OGL. So I will go ahead and setup ogl instead of being stubborn.
|
|
|
|
|
|