ifcpatch.recipes.Optimise#

Module Contents#

class ifcpatch.recipes.Optimise.Patcher(src, file, logger)#

Optimise the filesize of an IFC model

It is possible to non-losslessly optimise the filesize of an IFC model.

Note that this is usually not recommended. Optimising runs a risk of losing some indirect semantic data critical for native IFC authoring. Most parties who recommend optimisation are not aware of these risks. Optimising is only safe in the context of read-only IFCs.

If filesize is an issue, another approach would be to use IFCZIP instead to compress the model. Optimising the model only typically affects filesize and has minimal impact on load times. Large filesizes can usually be solved through other means. Consult the BlenderBIM Add-on documentation on dealing with large models for more details.

Warning: this optimise recipe is very, very slow. Please consider using RecycleNonRootedElements instead.

Example:

ifcpatch.execute({"input": "input.ifc", "file": model, "recipe": "Optimise", "arguments": []})
patch(self)#