Uploaded April 2012 | Updated September 2026, 1 week ago
If you keep your eyes fixated on the cross, you can see a very compelling colour after effect: If a dot disappears, it is replaced by an (illusory) dot of an opponent colour. For more information and other optical illusions, see http://www/cogsci.nl
If you keep your eyes fixated on the cross, you can see a very compelling colour after effect: If a dot disappears, it is replaced by an (illusory) dot of an opponent colour. For more information and other optical illusions, see http://www/cogsci.nl



![Python Decorators 3: Turning a function into a class instance
[https://www.buymeacoffee.com/cogsci] In this video, I show how you can use a decorator to replace a function with a callable class instance that also has methods (class functions) and properties.
You can download the Jupyter Notebook for this video from https://osf.io/2npaf/ Python Decorators 3: Turning a function into a class instance](https://i.ytimg.com/vi/jwcxlZvebDM/mqdefault.jpg)

![Using caching and memoization to optimize Python performance
[https://www.buymeacoffee.com/cogsci] In this video I explain the basics of caching and memoization (caching the results of function calls) and demonstrate how you can implement this using the functools.lru_cache decorator. For more Python tutorials, visit https://python.cogsci.nl/ Using caching and memoization to optimize Python performance](https://i.ytimg.com/vi/kt1ZxWFeTxs/mqdefault.jpg)

![Writing csv, tsv, xlsx files in Python
[https://www.buymeacoffee.com/cogsci] This is the first video of a two-part series on working with spreadsheet-like data in Python. Here I show how to write DataMatrix and pandas DataFrame objects to csv, tsv, and xlsx files. For more Python tutorials, visit https://python.cogsci.nl/ Writing csv, tsv, xlsx files in Python](https://i.ytimg.com/vi/lRerVytOQLU/mqdefault.jpg)
![Online psychology experiments with OSWeb and JATOS (#2): Distributing links
[https://www.buymeacoffee.com/cogsci] This is the second in a short series of videos on creating online psychology experiments with OSWeb/ OpenSesame and JATOS. In this video I show how to import your OpenSesame experiment into JATOS, and how to generate links that you can distribute to participants. Online psychology experiments with OSWeb and JATOS (#2): Distributing links](https://i.ytimg.com/vi/m1UDk5kBwH4/mqdefault.jpg)
![Publishing a Python package on pip [PythonLiveLessons #6]
Episode 6 of #PythonLiveLessons, a weekly live stream about Python code and more, hosted by Sebastiaan Mathôt. In this episode, well learn how to use pyproject.toml to add information about our package, and how to use flit to build our package and upload it to pypi so that users can easily install it with `pip install markdown_code_exec`. Publishing a Python package on pip [PythonLiveLessons #6]](https://i.ytimg.com/vi/mu7yct6hOSA/mqdefault.jpg)
![Completing a code sketch (exec and eval) [PythonLiveLessons #1]
Episode 1 of #PythonLiveLessons, a weekly live stream about Python code (with live coding) and more, hosted by Sebastiaan Mathôt. In this episode, well continue working on our Python project, `markdown_code_exec`. Well learn about the difference between expressions and statements, and the difference between eval() and exec(). At the end of this episode, well have a fully functional sketch of our program, which well develop further in future episodes! [To join a live broadcast, tune in to this YouTube channel on Tuesdays, 22:00 New Delhi, 18:00 Paris (CET), 09:00 Los Angeles.] Completing a code sketch (exec and eval) [PythonLiveLessons #1]](https://i.ytimg.com/vi/nBpVHmdXNuc/mqdefault.jpg)