Hacker Newsnew | past | comments | ask | show | jobs | submit | Xzya's commentslogin

> I am not familiar with Python Object Model enough but, if your Python example still allocates an object with slots for all 47 other fields besides the three selected, then you may still find yourself under circumstances you would rather have a "slim" version of the model and reduce memory allocation. This may be needed when you need to load dozens of thousands of entries into memory for processing or similar.

Alternatively you can also tell the ORM to return a dictionary rather than a model instance: https://docs.djangoproject.com/en/4.1/ref/models/querysets/#...

For example, you may get a list of dictionaries with only "field1", "field2" and "field3" from a model like this:

  SomeModel.objects.filter(...).values("field1", "field2", "field3")

  [{"field1": "foo", "field2": "bar", "field3": "baz"}]


I have been working on a library for Django that allows you to build reusable template components, and it is heavily inspired by Phoenix's Components. I just released it today, so if you are a Django user and find the way that Phoenix Components work interesting, give it a try!

https://github.com/Xzya/django-web-components


This project is very similar to django components https://pypi.org/project/django-components/


You may also find this interesting: https://github.com/fogleman/ln

You can turn 3D scenes into 2D vectors.


I have been following Anders Hoff [1][2]. He does some cool stuff with plotters.

I made an egg plotter back in the early 2000s based on The Art of Motion Control site [3], and then I went off to build CNC tables and do wood carvings in 3-axis, and then 4, and 5-axis machining. I am really interested in the community around making ceramic 3D printers where they mix their own clay. All creative and really cool stuff!

  [1] http://inconvergent.net/
  [2] https://twitter.com/inconvergent
  [3] http://www.taomc.com/



You can copy the device support from a newer version of Xcode to an older version, even if it does not run on your OSX version. Download the new Xcode > right click on it > show package contents > Contents > Developer > Platforms > iPhoneOS.platform > DeviceSupport, copy the versions you want from here (e.g. 10.3) to the same folder in the Xcode version that your OSX supports. After you open the new Xcode and connect your device it will process the symbols which can take a while, but after it's done you can debug apps again.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: