I. Basics
- Discuss the topic with me.
- The preferable programming languages are Kotlin or Python. Talk to me if you want to use any other language (Java, C++, C#, are generally ok).
II. Git and Pull Request
-
The code must be submitted via a pull request in a git repository
- Create an empty repository in bitbucket, GitHub, or MFF's GitLab
- Create a branch
- Commit all your code on that branch (not in master)
- Create a Pull Request
- Add me as a reviewer (jhana for bitbucket, jirka-x1 for GitHub)
- Send me a non-automated email about this with the subject "NPFL128 Project<yourfirstname><yourlastname><assignmentnumber>"
- You have to react to all comments of mine: add "fixed" if you agree and fixed it, ask for more detail, or disagree. But don't just fix or ignore it silently.
III. General
-
There is a readme file in the root (use markdown or plain text). It must specify
- What the project is solving (add a reference to the relevant paper)
- Scope - what you implemented and what is left for future
- How to run the project
- Add a file with sample output if appropriate
-
Do not use jupyter notebooks, write regular production-like code (the notebook can be added to provide an example of use, but it must call the regular functions you define)
-
Write functions that
-
solve a single well-defined task
-
are documented
-
are testable; bonus points for unit tests
-
ideally, the output is via the return value only. If any parameters have to be modified, document it
-
-
Use self-explanatory variable and function names
-
Document all functions (what they do, what is input, what is output); add other comments as appropriate
- You must use appropriate libraries to handle JSON, XML, csv, etc. Do not write the code yourself.
-
All files end with a newline (see: this)
IV. Python
-
Strictly follow the PEP8 code style; a reasonable IDE (e.g., IntelliJ IDEA, PyCharm, MS VS Code) checks this for you.
-
Use type hints
-
Use `with` to manipulate files.
-
Use argparse to parse arguments.
-
Consider using: pathlib's Path for all files and directories, Counter to count objects.