De Anza logo Course Outlines

Public Search

 
 
Close Window/Tab
PRINT VIEW -- Opens in new, second window. Use browser controls to close when finished.
Credit- Degree applicable
Effective Quarter: Fall 2021

I. Catalog Information

CIS 41B
Advanced Python Programming
4.5 Unit(s)

 

Requisites: Prerequisite: CIS 41A.

Hours: Lec Hrs: 48.00
Lab Hrs: 18.00
Out of Class Hrs: 96.00
Total Student Learning Hrs: 162.00

Description: This course continues from CIS 41A, Python Programming, covering some topics in more detail, and adding more advanced topics. Object oriented programming, data structures, and functions as first class objects are covered extensively. New topics include data analysis, data visualization, graphical user interface programming, web access, database access, multi-threading and multiprocessing, network socket programming, operating system calls, timing and profiling, and Python extensions.


Student Learning Outcome Statements (SLO)

 

• Student Learning Outcome: Design, code, document, analyze, debug, and test advanced level Python programs that include Python modules for database, networking, graphics, and extensions


II. Course Objectives

A.Investigate modules, packages and processing sequences
B.Investigate functions as first class objects
C.Apply calls to OS services
D.Design GUI classes
E.Analyze and visualize data
F.Develop code for web access
G.Construct database access
H.Design multithreading code
I.Design multiprocessing code
J.Write network socket code
K.Utilize programmer tools

III. Essential Student Materials

 None

IV. Essential College Facilities

 Lab with computers that have the Python interpreter, IDE (Integrated Development Environment), and Anaconda distribution installed

V. Expanded Description: Content and Form

A.Investigate modules, packages and processing sequences
1.Modules and packages
a.Namespace, naming convention, naming resolution
b.Create packages
2.Processing sequences
a.Iterator class
b.Generator expression
c.Generator function
d.The packing operator
e.The unpacking operator
B.Investigate functions as first class objects
1.Function reference
2.map, reduce, filter
3.Closures
4.Decorators
5.Lambda functions
C.Apply calls to OS services
1.The os module
2.Environment variables
3.Launching OS commands
4.Working with file systems
a.The os.path module
b.The shutil module
c.The sys module
1.Command line arguments
5.Date and time
D.Design GUI classes
1.GUI layout: concept of master
2.Widgets and window layout
3.Colors, fonts, text, and window resizing
4.Event handling
5.Callback and bind methods
6.Derive window classes from a GUI package
7.Coordinating windows in a GUI: update, wait, focus, grab, destroy
E.Analyze and visualize data
1.numpy array
a.Initializing and indexing
b.Arithmetic and logical operations
c.Common math and statistics computation
2.Plotting
a.Line graph, bar graph, histogram
b.Embed plots in a GUI front end
F.Develop code for web access
1.The urllib module and the requests package
2.Parsing HTML data
3.Web scraping and web crawling
4.Ethics of web scraping
5.The web API
a.JSON format
G.Construct database access
1.The DB API and available interfaces
2.Connecting to the SQLite3 DB
3.Parameterized statements
4.Metadata
a.Tables
b.Columns
c.Constraints
d.Foreign keys
5.DB Transactions
H.Design multithreading code
1.Python threads and the GIL
2.The threading module
3.Parent thread, child thread, daemon thread
4.Thread communication
a.Event
b.Lock, semaphore, and race conditions
c.Queue
5.The thread manager
6.GUI and multithreading
I.Design multiprocessing code
1.Process definition
2.The multiprocessing module
3.Process communication
a.Event
b.Lock
c.Queue
4.Process pool
a.map
b.async
J.Write network socket code
1.Sockets
2.Client and server sockets
3.Socket protocols
4.Threaded servers
5.Binary data and the pickle module
K.Utilize programmer tools
1.Analyzing and testing programs with unittest
2.Profiling programs

VI. Assignments

A.Required reading from the textbook and class notes
B.Programs: 5-8 programming projects, several with 200 or more lines of code and using multiple user-defined modules.

VII. Methods of Instruction

 Lecture and visual aids
Discussion of assigned reading
Discussion and problem solving performed in class
Quiz and examination review performed in class
Homework and extended projects
Collaborative learning and small group exercises
Collaborative projects
Laboratory discussion sessions and quizzes that evaluate the proceedings weekly laboratory exercises
In-class exploration of Internet sites

VIII. Methods of Evaluating Objectives

A.Evaluation of programming assignments for correctness, use of structured design principles, documentation and efficiency.
B.In-class lab problems, group collaboration problems, quiz questions and/or online tutorials requiring the ability to read and analyze code through debugging and writing snippets of code.
C.One or more midterm examinations requiring programming ability to develop an algorithm, evaluate code segments, and write code using specific programming constructs presented in the course.
D.A final examination requiring some programming ability to develop an algorithm, evaluate code segments, and write code using specific programming topics presented in the course.

IX. Texts and Supporting References

A.Examples of Primary Texts and References
1.Lutz, Mark: Learning Python, 5th edition. O'Reilly Media. ISBN: 978-1-4493-5573-9. 2013
2.python.org online documentation: https://docs.python.org/3/
B.Examples of Supporting Texts and References
1.Lubanovic, Bill: Introducing Python, 2nd Edition. O'Reilly. ISBN: 978-1492051367. 2019

X. Lab Topics

A.Write and debug code that work with multiple modules, generators, and data structures.
B.Write and debug code that implement first order and higher order functions, lambda functions, and decorators.
C.Write and debug code that calls OS services.
D.Write and debug code that uses a GUI to interact with the user.
E.Write and debug code that analyze data and provide data visualization.
F.Write and debug code that download, parse, and analyze HTML data.
G.Write and debug code that store and access data in an SQL database.
H.Write and debug multi-threaded code.
I.Write and debug multiprocessing code.
J.Write and debug client and server socket programming code.
K.Write, debug, analyze, and profile code for performance.