# p5py

**URL:** https://discourse.processing.org/c/p5py/27.md

[Latest](https://discourse.processing.org/latest.md) · [Categories](https://discourse.processing.org/categories.md) · [Tags](https://discourse.processing.org/tags.md)

---

## [About the p5py category](https://discourse.processing.org/t/about-the-p5py-category/23832)

<div class="topic-metadata">

**Author:** [@parsoyaarihant](https://discourse.processing.org/u/parsoyaarihant)\
**Replies:** 0\
**Last updated:** [September 13, 2020, 7:33am UTC](https://discourse.processing.org/t/about-the-p5py-category/23832 "2020-09-13T07:33:11Z")

</div>

p5py is a Python package based on the core ideas of Processing. It runs directly on Python 3 (rather than in the Processing PDE) and is installable in Python through pip install p5. For related discussions of Processi…

---

## [Default frame rate of app is painfully low, even with default settings of frame\_rate = 60](https://discourse.processing.org/t/default-frame-rate-of-app-is-painfully-low-even-with-default-settings-of-frame-rate-60/44036)

<div class="topic-metadata">

**Author:** [@danelyn](https://discourse.processing.org/u/danelyn)\
**Replies:** 1\
**Last updated:** [March 6, 2024, 4:24am UTC](https://discourse.processing.org/t/default-frame-rate-of-app-is-painfully-low-even-with-default-settings-of-frame-rate-60/44036 "2024-03-06T04:24:01Z")

</div>

As topic. I can run Processing’s Python mode with ease, but running a simple project that runs at 60fps on that Python mode, ported over to p5, runs at a painful frame rate. I’ve created a simple test app that just calc…

---

## [Saving images from drawing](https://discourse.processing.org/t/saving-images-from-drawing/43953)

<div class="topic-metadata">

**Author:** [@Kamel0](https://discourse.processing.org/u/Kamel0)\
**Replies:** 4\
**Last updated:** [February 27, 2024, 11:08am UTC](https://discourse.processing.org/t/saving-images-from-drawing/43953 "2024-02-27T11:08:04Z")

</div>

Hello, Can you point me to an example of saving image(s)? I want to save an image or sequence of images of what is drawn using p5py. I assume this relates to using the offscreen buffer. Please clarify. Thanks!

---

## [Looking for contributors to help with p5py :D](https://discourse.processing.org/t/looking-for-contributors-to-help-with-p5py-d/43407)

<div class="topic-metadata">

**Author:** [@tushar55](https://discourse.processing.org/u/tushar55)\
**Replies:** 0\
**Last updated:** [December 6, 2023, 7:08pm UTC](https://discourse.processing.org/t/looking-for-contributors-to-help-with-p5py-d/43407 "2023-12-06T19:08:52Z")

</div>

I worked on p5py as a fellow under the Processing Foundation where I worked on implementing a 2D renderer based on Skia. I am quite happy with the current beta version, there have been significant performance boosts and …

---

## [Please Help me optimise my app (uses p5 python port)](https://discourse.processing.org/t/please-help-me-optimise-my-app-uses-p5-python-port/24302)

<div class="topic-metadata">

**Author:** [@shade\_95](https://discourse.processing.org/u/shade_95)\
**Replies:** 1\
**Last updated:** [December 6, 2023, 6:55pm UTC](https://discourse.processing.org/t/please-help-me-optimise-my-app-uses-p5-python-port/24302 "2023-12-06T18:55:01Z")

</div>

https://github.com/1999shaswat/a-star Source Code in sketch.py My python program (shortest path using a star), worked fine in previous releases of p5py. (As shown in gif in github page \[ignore lag, peek gif recorder pr…

---

## [Subreddit Opened](https://discourse.processing.org/t/subreddit-opened/39279)

<div class="topic-metadata">

**Author:** [@appinv](https://discourse.processing.org/u/appinv)\
**Replies:** 1\
**Last updated:** [December 6, 2023, 6:52pm UTC](https://discourse.processing.org/t/subreddit-opened/39279 "2023-12-06T18:52:07Z")

</div>

Just a note that the p5py subreddit just opened! I intend to contribute some elements, so, stay tuned and feel free to post over there!

---

## [Error installing py5 in Windows 10 using Thonny](https://discourse.processing.org/t/error-installing-py5-in-windows-10-using-thonny/40080)

<div class="topic-metadata">

**Author:** [@maurix](https://discourse.processing.org/u/maurix)\
**Replies:** 13\
**Last updated:** [April 30, 2023, 4:24pm UTC](https://discourse.processing.org/t/error-installing-py5-in-windows-10-using-thonny/40080 "2023-04-30T16:24:32Z")

</div>

I’ve got this error installing py5 in the plug-in window in Thonny 4.0.1: –prefix= --compile --install-headers ‘C:\\Users\\mauri\\AppData\\Roaming\\Thonny\\plugins\\Python38\\Include\\jpype1’ Check the logs for full command outp…

---

## [Why is fetchall returning a list with only one entry, a tuple containing a string with the tuples, rather than a list of tuples?](https://discourse.processing.org/t/why-is-fetchall-returning-a-list-with-only-one-entry-a-tuple-containing-a-string-with-the-tuples-rather-than-a-list-of-tuples/41741)

<div class="topic-metadata">

**Author:** [@neon124](https://discourse.processing.org/u/neon124)\
**Replies:** 0\
**Last updated:** [April 16, 2023, 11:49pm UTC](https://discourse.processing.org/t/why-is-fetchall-returning-a-list-with-only-one-entry-a-tuple-containing-a-string-with-the-tuples-rather-than-a-list-of-tuples/41741 "2023-04-16T23:49:44Z")

</div>

It gives the following result: \[('("Murder in the First (1995)",2018,57)',), ('("U-571 (2000)",2020,53)',), ('("Money Train (1995)",2019,52)',), ('("Picnic at Hanging Rock (1975)",2019,52)',)\] Instead, try this: \[("Mu…

---

## [Processing on JupyterNotebook](https://discourse.processing.org/t/processing-on-jupyternotebook/41556)

<div class="topic-metadata">

**Author:** [@Ediacar2n](https://discourse.processing.org/u/Ediacar2n)\
**Replies:** 1\
**Last updated:** [April 1, 2023, 12:07pm UTC](https://discourse.processing.org/t/processing-on-jupyternotebook/41556 "2023-04-01T12:07:34Z")

</div>

Hi :wink: I’m new to Processing. Could I run processing on JupyterNotebook? Or how can I run it merely in a chunk or cell? I always modify different versions of drawings, but it’s illegible or confusing to //comment th…

---

## [Has PGraphics been renamed?](https://discourse.processing.org/t/has-pgraphics-been-renamed/36385)

<div class="topic-metadata">

**Author:** [@SNitaine](https://discourse.processing.org/u/SNitaine)\
**Replies:** 4\
**Last updated:** [September 7, 2022, 5:26pm UTC](https://discourse.processing.org/t/has-pgraphics-been-renamed/36385 "2022-09-07T17:26:37Z")

</div>

I can’t find any reference to createGraphics() or PGraphics in the p5py documentation. Has it been renamed?

---

## [Has anyone got P5 to work with Spout?](https://discourse.processing.org/t/has-anyone-got-p5-to-work-with-spout/38670)

<div class="topic-metadata">

**Author:** [@DusX](https://discourse.processing.org/u/DusX)\
**Replies:** 3\
**Last updated:** [September 15, 2022, 4:26pm UTC](https://discourse.processing.org/t/has-anyone-got-p5-to-work-with-spout/38670 "2022-09-15T16:26:20Z")

</div>

I am interested in outputting the video created with P5 via Spout. see: GitHub - jlai/Python-SpoutGL: Python wrapper for SpoutGL I have this working with Pygame, but I would rather use P5 Any help greatly appreciated. …

---

## [Couldn't load image into py5](https://discourse.processing.org/t/couldnt-load-image-into-py5/38503)

<div class="topic-metadata">

**Author:** [@Lyra](https://discourse.processing.org/u/Lyra)\
**Replies:** 2\
**Last updated:** [August 27, 2022, 12:24am UTC](https://discourse.processing.org/t/couldnt-load-image-into-py5/38503 "2022-08-27T00:24:07Z")

</div>

Hi, I’m a new user and just begin learning py5 in school, I’ve run the code with no errors appeared, but the sketch is blank, could anyone help me figure out the problem? Thank you so much! \< size(600,600) background(…

---

## [Print Ready Sketch Py5](https://discourse.processing.org/t/print-ready-sketch-py5/36094)

<div class="topic-metadata">

**Author:** [@sweetart](https://discourse.processing.org/u/sweetart)\
**Replies:** 3\
**Last updated:** [April 6, 2022, 12:06pm UTC](https://discourse.processing.org/t/print-ready-sketch-py5/36094 "2022-04-06T12:06:21Z")

</div>

Dear All, I started to use Py5 (https://py5.ixora.io/). Creating static and dynamic visual is going according to plan and I’m very happy with the Python version of Processing. However still one (important) challenge rem…

---

## [Force redraw() / redraw with callback](https://discourse.processing.org/t/force-redraw-redraw-with-callback/27246)

<div class="topic-metadata">

**Author:** [@odotdotdot](https://discourse.processing.org/u/odotdotdot)\
**Replies:** 2\
**Last updated:** [January 20, 2021, 9:12pm UTC](https://discourse.processing.org/t/force-redraw-redraw-with-callback/27246 "2021-01-20T21:12:32Z")

</div>

I have a p5py application that requires getting data from the internet on user input. I’m running the sketch with no\_loop() in the setup as animation is only required on user input. Fetching and processing the data can …

---

## [Deep Reinforcement Learning with Pytorch and Processing](https://discourse.processing.org/t/deep-reinforcement-learning-with-pytorch-and-processing/24453)

<div class="topic-metadata">

**Author:** [@willtl](https://discourse.processing.org/u/willtl)\
**Replies:** 6\
**Last updated:** [October 10, 2020, 1:48am UTC](https://discourse.processing.org/t/deep-reinforcement-learning-with-pytorch-and-processing/24453 "2020-10-10T01:48:26Z")

</div>

I was checking how to use Processing with Python support. However, I read that in order to use Python libraries I would have to place then in the folder of my Processing project. Moreover, I also read that I would not be…

---

## [Yap5 Repo Release](https://discourse.processing.org/t/yap5-repo-release/23899)

<div class="topic-metadata">

**Author:** [@fenjalien](https://discourse.processing.org/u/fenjalien)\
**Replies:** 3\
**Last updated:** [September 19, 2020, 3:00pm UTC](https://discourse.processing.org/t/yap5-repo-release/23899 "2020-09-19T15:00:06Z")

</div>

Hi all, this is to announce that I have made the yap5 repository public. Its an experimental rewrite of p5py/p5 that instead uses pyglet as its graphics backend. Read the README in the repo for more details. Slight d…

---

## [API compatibility for p5py](https://discourse.processing.org/t/api-compatibility-for-p5py/20492)

<div class="topic-metadata">

**Author:** [@villares](https://discourse.processing.org/u/villares)\
**Replies:** 10\
**Last updated:** [September 19, 2020, 11:39am UTC](https://discourse.processing.org/t/api-compatibility-for-p5py/20492 "2020-09-19T11:39:33Z")

</div>

@tabreturn has posted a great tutorial on how to use Thonny IDE with p5 (also known as p5py) here: Portable Thonny and p5 I find the p5py maintainers decision to forgo any attempt at API compatibility with Py.Processing…

---

## [Push and pop not working in p5py?](https://discourse.processing.org/t/push-and-pop-not-working-in-p5py/21653)

<div class="topic-metadata">

**Author:** [@renec112](https://discourse.processing.org/u/renec112)\
**Replies:** 2\
**Last updated:** [June 13, 2020, 8:14pm UTC](https://discourse.processing.org/t/push-and-pop-not-working-in-p5py/21653 "2020-06-13T20:14:30Z")

</div>

I’m using the python package p5python package p5 I’m following some tutorials written in javascript, but it seems like push and pop is not the same in the python package. I’m using the push\_matrix() and the pop\_matrix(…

---

## [Make p5py loop run for 90 frames exaclty?](https://discourse.processing.org/t/make-p5py-loop-run-for-90-frames-exaclty/20736)

<div class="topic-metadata">

**Author:** [@renec112](https://discourse.processing.org/u/renec112)\
**Replies:** 2\
**Last updated:** [May 11, 2020, 8:19am UTC](https://discourse.processing.org/t/make-p5py-loop-run-for-90-frames-exaclty/20736 "2020-05-11T08:19:38Z")

</div>

I’m using the p5 python lib https://github.com/p5py/p5 I would love to do an animation scence that is 3 seconds long. So the draw loop should run for 90 frames, with 30 frames a second. I’m trying to do this by using n…

---

## [Default anti-aliasing causing the issue?](https://discourse.processing.org/t/default-anti-aliasing-causing-the-issue/18616)

<div class="topic-metadata">

**Author:** [@Vivek2898](https://discourse.processing.org/u/Vivek2898)\
**Replies:** 1\
**Last updated:** [March 12, 2020, 7:58pm UTC](https://discourse.processing.org/t/default-anti-aliasing-causing-the-issue/18616 "2020-03-12T19:58:29Z")

</div>

Hi, I’ve been looking into issue #19 lately. I think that it might’ve been because smooth() is not implemented in the native p5py. Also, referring to the progress sheet, I say that the default is left for anti-aliasing…

---

## [Running processing function and code from python ide](https://discourse.processing.org/t/running-processing-function-and-code-from-python-ide/3969)

<div class="topic-metadata">

**Author:** [@pradeep6081](https://discourse.processing.org/u/pradeep6081)\
**Replies:** 3\
**Last updated:** [October 1, 2018, 7:23pm UTC](https://discourse.processing.org/t/running-processing-function-and-code-from-python-ide/3969 "2018-10-01T19:23:03Z")

</div>

I found various documentation and example on running python script in processing. Is it possible to execute processing function and code from python ide. Thank You
