MacInsiders Logo

Similar Threads
Thread Thread Starter Forum Replies Last Post
Engineering 1D04 ericvan1 1st Year Course Reviews 14 06-12-2015 10:56 PM
any different ways to take 1D04? twinklingme Academics 10 06-04-2010 08:17 PM
1d04 lab endearing66 Academics 2 01-04-2010 01:02 PM
Engineering 1D04 IDE TheAxtmann First-Year / Prospective Student Questions 5 09-17-2009 02:39 PM
First Year Engineering: 1P03, 1C03 and 1D04. ruffy General Discussion 7 07-08-2009 06:00 PM

Need some help with Python in Engineering 1D04?

 
Old 09-27-2010 at 02:11 PM   #1
aaront
CSD HYPE Web Developer
Join Date: Sep 2007
Posts: 330

Thanked: 29 Times
Liked: 78 Times




Need some help with Python in Engineering 1D04?
Hey first-year engineers,

Just wondering if anyone needs any help with Python in 1D04. I've been programming in Python for a couple of years now, and wondering if I could be of use to anyone.

Just post your question below, and I'll try to answer it to the best of my knowledge.

Due to my limited time, I may not be able to answer every question in a timely matter, but I will try and answer all of them.

Happy Pythoning!

P.S. What are your assignments like? What Python editor are you using?
__________________
Software Engineering Class of '11

Leeoku likes this.
Old 09-27-2010 at 03:48 PM   #2
daliwangsun
Member
Join Date: Aug 2010
Posts: 19

Thanked: 0 Times
Liked: 1 Time




we use I.D.L.E ! i will come and get u when i have question
Old 09-27-2010 at 04:03 PM   #3
aaront
CSD HYPE Web Developer
Join Date: Sep 2007
Posts: 330

Thanked: 29 Times
Liked: 78 Times




Quote:
Originally Posted by daliwangsun View Post
we use I.D.L.E ! i will come and get u when i have question
Which version of Python, if you don't mind? 2.4? 2.5? 2.6? Just so I can help better.
__________________
Software Engineering Class of '11
Old 09-27-2010 at 08:28 PM   #4
Fawad2010
Member
Join Date: Aug 2010
Posts: 28

Thanked: 1 Time
Liked: 1 Time




its 2.66 this year. i will come here when i will need help for sure! thanks
Old 10-13-2010 at 09:12 PM   #5
aaront
CSD HYPE Web Developer
Join Date: Sep 2007
Posts: 330

Thanked: 29 Times
Liked: 78 Times




Anyone have any problems/questions yet?
__________________
Software Engineering Class of '11
Old 10-13-2010 at 09:51 PM   #6
Ownaginatios
Trolling ain't easy
Join Date: Jul 2008
Posts: 3,190

Thanked: 499 Times
Liked: 1,642 Times




Quote:
Originally Posted by aaront View Post
Anyone have any problems/questions yet?
Heh, I'm obviously not in 1D04, but I do have some questions about Python I think you may be able to answer.

How do I integrate python with a webpage (you know, like how PHP does)? Is there something you just drop into your apache server to make it work?

I'm thinking of creating an application for my WRT54GL in C to dump bandwidth usage to an SQL database, and Python's ability to easily make graphs and stuff for a webpage is rather intriguing.
__________________
Dillon Dixon
Alumni
Software Engineering and Embedded Systems
Old 10-13-2010 at 10:13 PM   #7
aaront
CSD HYPE Web Developer
Join Date: Sep 2007
Posts: 330

Thanked: 29 Times
Liked: 78 Times




Quote:
Originally Posted by Ownaginatios View Post
Heh, I'm obviously not in 1D04, but I do have some questions about Python I think you may be able to answer.

How do I integrate python with a webpage (you know, like how PHP does)? Is there something you just drop into your apache server to make it work?

I'm thinking of creating an application for my WRT54GL in C to dump bandwidth usage to an SQL database, and Python's ability to easily make graphs and stuff for a webpage is rather intriguing.
Python (fortunately?) doesn't mix logic with the view, so you'll have to use templating and a framework.

So, I would suggest to use a lightweight framework, like Flask (http://flask.pocoo.org/), which also has the best documentation of any software project I know. I highly recommend following the tutorial, then asking me again if you have any questions. You can then deploy with mod_wsgi for Apache, http://flask.pocoo.org/docs/deploying/mod_wsgi/, a very trivial task. Again the documentation is really good.

To set up your Python, (assuming you're using Ubuntu), install setuptools and virtualenv.

Code:
sudo apt-get install python-setuptools python-virtualenv
setuptools provides the easy_install command to easily install Python modules.

virtualenv isolates your development environment to allow you to install modules for this project only, in a contained environment. It's great for decluttering your system Python modules folder.

More info on setting up is here: http://flask.pocoo.org/docs/installation/

If you have any questions, feel free to ask. I've been using (and having fun with) Flask (and Pylons, it's big brother) for about a year or so.
__________________
Software Engineering Class of '11
Old 10-29-2010 at 04:21 PM   #8
aaront
CSD HYPE Web Developer
Join Date: Sep 2007
Posts: 330

Thanked: 29 Times
Liked: 78 Times




*whistles*

I'm bored. Anyone need some help?
__________________
Software Engineering Class of '11
Old 10-29-2010 at 04:29 PM   #9
ViktorVaughn
Senior Member
Join Date: Mar 2009
Posts: 207

Thanked: 26 Times
Liked: 71 Times




What happened to C?
Old 10-29-2010 at 04:35 PM   #10
Juve
Elite Member
Join Date: Sep 2010
Posts: 502

Thanked: 11 Times
Liked: 117 Times




i need help with psychology
__________________
if your heart is a volcano , how shall you expect flowers to bloom?
Old 10-30-2010 at 05:27 PM   #11
aaront
CSD HYPE Web Developer
Join Date: Sep 2007
Posts: 330

Thanked: 29 Times
Liked: 78 Times




Quote:
Originally Posted by ViktorVaughn View Post
What happened to C?
Traded in for C#, now swapped for Python.
__________________
Software Engineering Class of '11
Old 11-05-2010 at 11:33 PM   #12
Commander
P.I.M.P
Join Date: Jul 2010
Posts: 488

Thanked: 13 Times
Liked: 63 Times




Programming can be fun or a pain in the butt. It's fun when you enjoy, but when there's pressure it's not.

Last edited by Commander : 11-05-2010 at 11:59 PM.
Old 11-06-2010 at 12:27 AM   #13
blackdragon
Elite Member
Join Date: Aug 2008
Posts: 2,412

Thanked: 152 Times
Liked: 339 Times




Psh. They should just teach Java first year
__________________
Electrical Engineering Alumni
Old 11-06-2010 at 01:49 AM   #14
Patrick.O
Senior Member
Join Date: May 2010
Posts: 222

Thanked: 29 Times
Liked: 28 Times




Quote:
Originally Posted by blackdragon View Post
Psh. They should just teach Java first year
They do for the Comp Sci students.
Old 11-06-2010 at 08:14 AM   #15
aaront
CSD HYPE Web Developer
Join Date: Sep 2007
Posts: 330

Thanked: 29 Times
Liked: 78 Times




Quote:
Originally Posted by blackdragon View Post
Psh. They should just teach Java first year
Yuck. Java is not the be all and end all.

I think they chose Python because:
  1. It's free to obtain and a small download
  2. It's similar to MATLAB, which many will use in the future
  3. It's easy to understand and pseudocode-like
__________________
Software Engineering Class of '11



Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



McMaster University News and Information, Student-run Community, with topics ranging from Student Life, Advice, News, Events, and General Help.
Notice: The views and opinions expressed in this page are strictly those of the student(s) who authored the content. The contents of this page have not been reviewed or approved by McMaster University or the MSU (McMaster Students Union). Being a student-run community, all articles and discussion posts on MacInsiders are unofficial and it is therefore always recommended that you visit the official McMaster website for the most accurate up-to-date information.

Copyright © MacInsiders.com All Rights Reserved. No content can be re-used or re-published without permission. MacInsiders is a service of Fullerton Media Inc. | Created by Chad
Originally Powered by vBulletin®, Copyright © 2019 MH Sub I, LLC dba vBulletin. All rights reserved. | Privacy | Terms