Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
Practicum Lecture Notes
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Saleh Aghajani
Practicum Lecture Notes
Commits
4c85d50c
Commit
4c85d50c
authored
5 years ago
by
Gary Steele
Browse files
Options
Downloads
Patches
Plain Diff
forgot the nerd notebook in zipfile...added it separately for now in brightspace
parent
f357ef74
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
create zipfile.ipynb
+1
-0
1 addition, 0 deletions
create zipfile.ipynb
create zipfile.md
+1
-0
1 addition, 0 deletions
create zipfile.md
with
2 additions
and
0 deletions
create zipfile.ipynb
+
1
−
0
View file @
4c85d50c
...
@@ -46,6 +46,7 @@
...
@@ -46,6 +46,7 @@
"files += glob(\"Notebook 5/exercise_data.dat\")\n",
"files += glob(\"Notebook 5/exercise_data.dat\")\n",
"files += glob(\"Notebook 5/v_vs_time.dat\")\n",
"files += glob(\"Notebook 5/v_vs_time.dat\")\n",
"files += glob(\"Outline of notebooks.ipynb\")\n",
"files += glob(\"Outline of notebooks.ipynb\")\n",
"files += glob(\"Additional*/*\")\n",
"\n",
"\n",
"for f in files:\n",
"for f in files:\n",
" print(f)\n",
" print(f)\n",
...
...
%% Cell type:code id: tags:
%% Cell type:code id: tags:
```
python
```
python
# https://stackoverflow.com/questions/458436/adding-folders-to-a-zip-file-using-python
# https://stackoverflow.com/questions/458436/adding-folders-to-a-zip-file-using-python
import
zipfile
import
zipfile
from
glob
import
glob
from
glob
import
glob
from
datetime
import
datetime
from
datetime
import
datetime
outname
=
"
Lecture_Notebooks_
"
+
datetime
.
now
().
strftime
(
"
%Y-%m-%d
"
)
+
"
.zip
"
outname
=
"
Lecture_Notebooks_
"
+
datetime
.
now
().
strftime
(
"
%Y-%m-%d
"
)
+
"
.zip
"
outfile
=
zipfile
.
ZipFile
(
outname
,
"
w
"
)
outfile
=
zipfile
.
ZipFile
(
outname
,
"
w
"
)
files
=
[]
files
=
[]
files
+=
glob
(
"
*/Notebook*ipynb
"
)
files
+=
glob
(
"
*/Notebook*ipynb
"
)
files
+=
glob
(
"
Course_Information/*
"
)
files
+=
glob
(
"
Course_Information/*
"
)
files
+=
glob
(
"
Notebook*/*png
"
)
files
+=
glob
(
"
Notebook*/*png
"
)
files
+=
glob
(
"
Notebook 5/exercise_data.dat
"
)
files
+=
glob
(
"
Notebook 5/exercise_data.dat
"
)
files
+=
glob
(
"
Notebook 5/v_vs_time.dat
"
)
files
+=
glob
(
"
Notebook 5/v_vs_time.dat
"
)
files
+=
glob
(
"
Outline of notebooks.ipynb
"
)
files
+=
glob
(
"
Outline of notebooks.ipynb
"
)
files
+=
glob
(
"
Additional*/*
"
)
for
f
in
files
:
for
f
in
files
:
print
(
f
)
print
(
f
)
outfile
.
write
(
f
,
f
,
zipfile
.
ZIP_DEFLATED
)
outfile
.
write
(
f
,
f
,
zipfile
.
ZIP_DEFLATED
)
outfile
.
close
()
outfile
.
close
()
```
```
%% Output
%% Output
Notebook 3/Notebook 3 Program Flow Control.ipynb
Notebook 3/Notebook 3 Program Flow Control.ipynb
Notebook 4/Notebook 4 Scientific Computing with Numpy.ipynb
Notebook 4/Notebook 4 Scientific Computing with Numpy.ipynb
Notebook 5/Notebook 5 Data in Python.ipynb
Notebook 5/Notebook 5 Data in Python.ipynb
Notebook 2/Notebook 2 Functions.ipynb
Notebook 2/Notebook 2 Functions.ipynb
Notebook 1/Notebook 1 Python Basics.ipynb
Notebook 1/Notebook 1 Python Basics.ipynb
Course_Information/Frequently Asked Questions.ipynb
Course_Information/Frequently Asked Questions.ipynb
Course_Information/Python in the practicum.md
Course_Information/Python in the practicum.md
Course_Information/cell_type.png
Course_Information/cell_type.png
Course_Information/Installation Instructions.md
Course_Information/Installation Instructions.md
Course_Information/Python in the practicum.ipynb
Course_Information/Python in the practicum.ipynb
Course_Information/Installation Instructions.ipynb
Course_Information/Installation Instructions.ipynb
Course_Information/Frequently Asked Questions.md
Course_Information/Frequently Asked Questions.md
Notebook 1/anatomy_of_an_error.png
Notebook 1/anatomy_of_an_error.png
Notebook 1/behind_the_scenes.png
Notebook 1/behind_the_scenes.png
Notebook 1/stop_button.png
Notebook 1/stop_button.png
Notebook 5/exercise_data.dat
Notebook 5/exercise_data.dat
Notebook 5/v_vs_time.dat
Notebook 5/v_vs_time.dat
Outline of notebooks.ipynb
Outline of notebooks.ipynb
...
...
This diff is collapsed.
Click to expand it.
create zipfile.md
+
1
−
0
View file @
4c85d50c
...
@@ -29,6 +29,7 @@ files += glob("Notebook*/*png")
...
@@ -29,6 +29,7 @@ files += glob("Notebook*/*png")
files
+=
glob
(
"
Notebook 5/exercise_data.dat
"
)
files
+=
glob
(
"
Notebook 5/exercise_data.dat
"
)
files
+=
glob
(
"
Notebook 5/v_vs_time.dat
"
)
files
+=
glob
(
"
Notebook 5/v_vs_time.dat
"
)
files
+=
glob
(
"
Outline of notebooks.ipynb
"
)
files
+=
glob
(
"
Outline of notebooks.ipynb
"
)
files
+=
glob
(
"
Additional*/*
"
)
for
f
in
files
:
for
f
in
files
:
print
(
f
)
print
(
f
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment