|
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. |
Overall you should always remember: "Do I get something out of working overtime to meet deadlines?" - you can learn something (implementing stupid/fun features in school) - better grades (school) - more money - additional vacation - better chance at promotion - doing someone a favour the person will return
If there's no reason to work overtime to meet a deadline then don't do it. You're not a code monkey, and there are plenty of jobs where you're not required to work overtime without compensation. We're still an industry where there are too few great coders, so those people can chose their job. So if overtime is regularly _expected_ of you with no compensation - get another job. Yes, this basically applies to the average game dev studio
|
i work in a field that has almost more open jobs than applicants, so i dont have to take the abuse that game devs have to take often.
Of course i sometimes even do voluntary work to get my ideas done, but you should not have regular overtimes just because the guy managing your work is not capable. In the end, in a decent company, it will be figured out who is to blame when projects fail or delay. And its not because a programmer refused to work 12 hours a day.
Worry about your specific tasks at work and excell at them, it will make for a better and healthier life and you still get recognition.
|
i am familiarizing myself with windowing. decided to work with xlib (also looked at sdl, glfw, and some other). made a supersimple chalkboard (used same fsm framework as last post).
+ Show Spoiler [xlib module] +#define XK_LATIN1 #include<X11/Xlib.h> #include<X11/keysymdef.h>
namespace xlib{
struct application{ Display* display{XOpenDisplay(nullptr)}; Window root_window{XDefaultRootWindow(display)}; int screen_number{XDefaultScreen(display)}, depth{XDefaultDepth(display,screen_number)}, xcoord{0}, ycoord{0}; unsigned long black_pixel{XBlackPixel(display,screen_number)}, white_pixel{XWhitePixel(display,screen_number)}, border{white_pixel}, background{black_pixel}; unsigned int width{640}, heigth{480}, border_width{4}, window_class{InputOutput}; GC gc{XDefaultGC(display,screen_number)}; Visual* visual{XDefaultVisual(display,screen_number)}; Window window{ XCreateSimpleWindow(display,root_window,xcoord,ycoord,width,heigth,border_width,border,background) }; application(){ XSelectInput( display, window, KeyPressMask|PointerMotionMask ); XSetForeground(display,gc,white_pixel); XMapWindow(display,window); XFlush(display); } ~application(){ XUnmapWindow(display,window); XDestroyWindow(display,window); XCloseDisplay(display); } };
}
xlib::application application; + Show Spoiler [chalkboard fsm engine] +struct chalkboard { struct not_drawing{}; struct drawing{}; using states=seq::sequence<not_drawing,drawing>; static constexpr not_drawing initial{};
struct close{}; struct toggle_pause{}; struct mouse_position{int x; int y;}; using symbols=seq::sequence<close,toggle_pause,mouse_position>;
bool done{false};
//transitions //syntax: to_state operator()(const from_state&,const symbol&)
//draw a point drawing operator()(const drawing&,const mouse_position& m) { XDrawPoint(application.display,application.window,application.gc,m.x,m.y); }
template<class state> using other_state=seq::element<states,(seq::index<states,state>()+1)%2>;
//toggle to other state template<class state> other_state<state> operator()(const state&,const toggle_pause&) {}
//notify finished template<class state> state operator()(const state&,const close& c) { done=true; }
//catch all template<class state,class symbol> state operator()(const state&,const symbol&) {}
}; + Show Spoiler [main loop / event processor] + int main(int argc,char** argv) { try{ fsm::machine<chalkboard> fsm; XEvent event; do{ XNextEvent(application.display,&event); switch(event.type){ case KeyPress: switch(XLookupKeysym(&event.xkey,0)){ case XK_q: fsm|chalkboard::close{}; break; case XK_p: fsm|chalkboard::toggle_pause{}; break; } case MotionNotify: fsm|chalkboard::mouse_position{event.xmotion.x,event.xmotion.y}; break; } }while(!fsm.done); }catch(const std::exception& e){ std::cerr<<e.what()<<std::endl; } }
new logo for tl:
|
|
|
ugh xlib ~_~
use opengl or some library imo unelss you just want to learn at that low level. xlib is pretty useless.
|
So this is not a real programming related question, but i guess you guys have the most experience with it. I'm planning on getting a laptop, just to be able to program while I'm relaxing on the couch or in my bed. I don't want to have a 17" laptop, since i feel that is just to big.
I got offered a HP Elitebook 2560P for a fairly cheap price.
Since I will just be running Visual Studio and a light weight text editor on it, the specs are fine. The only thing I'm afraid of, is that 12.5" is to small to work on comfortably.
Do any of you guys have any experience using smaller sized laptops for programming?
|
|
|
|
|
i got 5/10 for my problem statement....
problem statement + Show Spoiler + Comparing the runtime performance of a concurrent process written using the Actor Model vs the traditional shared-state model of parallel programming.
The Actor Model is an emerging methodology that offers an alternative approach to the traditional shared-state model of parallel programming. Although much debate surrounds the usefulness of the Actor Model in real-world application, this debate tends to surround issues of architectural design rather than runtime performance. This paper aims to evaluate the performance of the Actor Model by measuring the execution time of a scalable asynchronous application and then comparing this with a similar build based on a traditional shared-state model. To achieve this a process will be built in node.js that sends an array of concurrent HTTP requests to The Internet Movie Database and listens for an XML response. The process will be iterated for accuracy and runtime will be recorded using JavaScript’s built-in getMilliseconds function. The application will be constructed two times; once with the nactor library using the Actor Model and once with the async library using traditional shared-state programming. Measured run-times in milliseconds will be compared in order to establish a conclusion.
tutors comments (make sense of this if you can) + Show Spoiler + You propose an evaluation rather than a problem. You do state how you will do your evaluation and your measurable's. But the idea of this work was to investigate a problem rather than evaluate processes. Have you got the resources to conduct your testing? refine this work to an actual problem. then work from there. 5/10
my comments + Show Spoiler + im not sure she understands what i wrote? "u propose an evaluation rather than a problem" doesn't make any sense? yes i listed ~7 resources.
what does it mean "But the idea of this work was to investigate a problem rather than evaluate processes."
i spent 20 mins talking to non-english friend him saying that "its not a problem" and me saying "it is a problem"
|
|
|
On December 15 2014 19:29 Manit0u wrote:You do propose the eveluation rather than a problem...
what does that mean? i say "Although much debate surrounds the usefulness of the Actor Model in real-world application, this debate tends to surround issues of architectural design rather than runtime performance. This paper aims to evaluate the performance....."
if what you're saying is that i'm not explicit enough then i can see how that's a possibility if you suck at reading two consecutive sentences but then it doesn't seem to explain "But the idea of this work was to investigate a problem rather than evaluate processes."
can i restate that the problem is that no1 has measured the runtime performance of actor model vs other model and hence that is what i am investigating
ok so im guessing my first sentence isn't as clear as i thought it was. i say that there is debate about usefulness of actor model. i say that debate doesnt surround issues of runtime performance. i say that i am going to measure runtime performance.
i'm guessing the confusion is because that i don't clearly state that there is no research on runtime performance and that is a problem and therefore i am going to do it.
am i right or am i wrong?
edit: no i still dont understand from your link
|
On December 15 2014 19:31 FFGenerations wrote:Show nested quote +On December 15 2014 19:29 Manit0u wrote:This paper aims to evaluate the performance You do propose the eveluation rather than a problem... what does that mean? i say "Although much debate surrounds the usefulness of the Actor Model in real-world application, this debate tends to surround issues of architectural design rather than runtime performance. This paper aims to evaluate the performance....." if what you're saying is that i'm not explicit enough then i can see how that's a possibility if you suck at reading two consecutive sentences but then it doesn't seem to explain "But the idea of this work was to investigate a problem rather than evaluate processes." can i restate that the problem is that no1 has measured the runtime performance of actor model vs other model and hence that is what i am investigating ok so im guessing my first sentence isn't as clear as i thought it was. i say that there is debate about usefulness of actor model. i say that debate doesnt surround issues of runtime performance. i say that i am going to measure runtime performance. i'm guessing the confusion is because that i don't clearly state that there is no research on runtime performance and that is a problem and therefore i am going to do it. am i right or am i wrong?
A problem is something to solve, a reason for finding a solution. What you are proposing is basically research for the sake of research. Saying "I'm researching it because I have the problem of there not being research" is not creating a problem to solve, it's fancy wording for "I'm too lazy to find a real problem for which I could apply my 'solution'".
What is the underlying problem? Why would someone start to dig into the actor model and evaluate it's performance? Which real world high performance application for that pattern either doesn't exist and could be improved or exists and could be improved by not using that pattern?
Think of having a boss that only thinks about the business value of the time you spend. Spending 20 hours researching a pattern for the sake of it will cost your job unless you can point very specifically to why it has to be done.
Simple example (that you shouldn't use because it's too simplified): "Our customers are complaining about poor performance of our legacy services. Those services don't allow for solving it with more hardware due to technical constraints. Since they are using a shared-state model, we could use the actor model to potentially speed it up, which would require rewriting core parts of the application. If it doesn't produce noticeable performance benefits then it's a waste of time, i.e. money, and the time might be better spent improving other parts of the code, so we have to evaluate the performance for this use-case before starting work on this code."
|
From what you have posted here the problem is that no one has evaluated this before? And to solve that problem you are going to evaluate it?
I'd tend to agree with your tutor on this one.
|
On December 15 2014 02:24 Nesserev wrote:Show nested quote +On December 15 2014 01:27 McDutch wrote:So this is not a real programming related question, but i guess you guys have the most experience with it. I'm planning on getting a laptop, just to be able to program while I'm relaxing on the couch or in my bed. I don't want to have a 17" laptop, since i feel that is just to big. I got offered a HP Elitebook 2560P for a fairly cheap price. Since I will just be running Visual Studio and a light weight text editor on it, the specs are fine. The only thing I'm afraid of, is that 12.5" is to small to work on comfortably. Do any of you guys have any experience using smaller sized laptops for programming? As long as it's not part of your primary programming environment, a small screen won't hurt. What I mean is, I hope that you have a multi-monitor desktop set up at home, or at your job, where you do most of your coding, and if you just want to use it for when you're relaxing on the couch or in bed, it's a good option. But, if you're going to use an IDE like Visual Studio, it's probably a good idea not to go for a notebook with a 12" screen. Do you currently have a 15"-17" laptop, because if you just 'think' that a 17" laptop might be to big, you might be surprised. I use a 17" laptop for the same purposes and never thought that it was too big... in fact, I wouldn't dare to go smaller. I think it all comes down to personal opinion and getting used to things. 12" might be too small, I consider 17" screens to be the safe option.
My gf has a 17" laptop. I just feel like it's to big to use without a desk to put it on. I used someone's 13" macbook, and i found that fine to use for a small amount of time. I agree you shouldn't use it as your primary work station, but that is what my desktop is for. But sometimes i don't feel like working on my desk all day, and want to work like 30/45min on the couch.
The problem is resolution tho. Most 12"/13" laptops do not have a full HD monitor. Unless i would buy a macbook retina i guess, but that's just money waste.
|
at work i had a variant of ~50 types (representing the alphabet of symbols in some language). i had written several different binary visitations (i was in a hurry, so no time to be precise). ergo several cases of the compiler instantiating 50*50=2500 functions with template machinery and stuffing them in an array. really amazing that it worked (took long to compile, but not so long it was impossible to work with).
now that i got the opportunity to improve my previous work i rewrote the visitor machinery to be more general (~with more involved template machinery), but as a result the compilator started choking out because it ran out of heap space, so now i am rewriting my classes to be a bit more precise (variants hold fewer types) to ease the pain.
maybe if i was using gcc or clang i would have gotten away with it (using vs2014). with gcc (on my workstation 8gb mem) i can instantiate 75*75=5625 functions without choking, but not a lot more. it seems template instantiations really blow up memory-wise when you get serious with them. dunno to what order it blows up with, but wouldn't be surprised if it was 3 or more!
been conforming to the codestyle at work, writing captial letters and camel case. so vulgar, but it feels nice in a GuiltyPleasureKindOfWay.
|
-nuked
User was banned for this post.
|
Latest client demands: "I want to upload .avi, .rm and .swf videos to the website and I want them all to play no problem in every browser, including mobiles."
FML
|
On December 19 2014 19:58 Manit0u wrote: Latest client demands: "I want to upload .avi, .rm and .swf videos to the website and I want them all to play no problem in every browser, including mobiles."
FML Haha good stuff.
|
|
|
On December 19 2014 19:58 Manit0u wrote: Latest client demands: "I want to upload .avi, .rm and .swf videos to the website and I want them all to play no problem in every browser, including mobiles."
FML ok, lets split and see
"I want to upload .avi, .rm and .swf videos to the website" ETA 2 days
"and I want them all to play no problem in every browser, including mobiles." ETA 90 days
Joke aside, tell him to define "all to play no problem". These... people, man. The cringe. What does that even mean? Does he want every browser known to mankind, ever since Adam and Eve ate the apple?
Does he want a shiny sparkling frame and unicorns dancing around the video? Does he want fullscreen? Does he want no framedrops? Does he provide every single gadget from the category "including mobiles" to test on it? Did he provide the mockup for the upload user interface? Does he know what a mockup is?
These fucking marketing people. Be very careful with this guy's demands, you cannot even play swf on iOS and he will most probably complain. Establish your rules on whats supported and what isnt, tell him you need 24hrs to get facts straight and a compatibility list.
|
|
|
|
|
|