Dion Moult
6e30cd2ba7
Fix #4638 . You can now filter by parent (in the spatial hierarchy)
2024-06-01 15:10:45 +10:00
Dion Moult
0f9ea1e1e7
New utility functions to get parent in spatial hierarchy, filled void, and voided element
2024-06-01 15:09:05 +10:00
Dion Moult
128ffc8fd7
Fix bug where selector didn't handle "not equals" correctly for locations or groups
2024-06-01 14:53:55 +10:00
Andrej730
162e66b775
typing
2024-05-31 18:20:46 +05:00
Andrej730
45a1655485
typing
2024-05-29 18:00:44 +05:00
Andrej730
ce26d931c1
regenerate ifc4x3 pset templates after the release
...
Change log
Different props in pset 'Pset_BuildingCommon':
- new props: ElevationOfTerrain, ElevationOfRefHeight
New template 'Pset_DoorLiningProperties' with props: LiningDepth, LiningThickness, ThresholdDepth, ThresholdThickness, TransomThickness, TransomOffset, LiningOffset, ThresholdOffset, CasingThickness, CasingDepth, LiningToPanelOffsetX, LiningToPanelOffsetY
New template 'Pset_DoorPanelProperties' with props: PanelDepth, PanelOperation, PanelWidth, PanelPosition
New template 'Pset_PermeableCoveringProperties' with props: OperationType, PanelPosition, FrameDepth, FrameThickness
Different props in pset 'Pset_Stationing':
- new props: HasIncreasingStation
New template 'Pset_WindowLiningProperties' with props: LiningDepth, LiningThickness, TransomThickness, MullionThickness, FirstTransomOffset, SecondTransomOffset, FirstMullionOffset, SecondMullionOffset, LiningOffset, LiningToPanelOffsetX, LiningToPanelOffsetY
New template 'Pset_WindowPanelProperties' with props: OperationType, PanelPosition, FrameDepth, FrameThickness
2024-05-28 18:01:33 +05:00
Andrej730
eeaa0a5530
Fill IfcPropertySetTemplate.TemplateType in ifc2x3 pset templates
2024-05-28 18:00:22 +05:00
Dion Moult
54951d2102
Add convenience max/min functions for xyz and side_area shape calculations
2024-05-28 17:30:01 +10:00
Dion Moult
8403c32e76
Adjust selector's behaviour to use the elements argument as a filtering subset
...
This was always the original intention, but never worked as designed. This is so that you don't need to filter the entire file (which can be huge).
2024-05-28 17:30:01 +10:00
Andrej730
02fd78df14
datetime2ifc to support None values as it was before ebd03e9 #4734
2024-05-27 17:34:28 +05:00
Dion Moult
7142f3856c
Add documentation for some unit utilities
2024-05-27 09:42:28 +10:00
Dion Moult
37cacfcd06
Fix #4728 . Bug where changing class doesn't work with IfcCSV if it didn't need to change anything.
2024-05-26 21:57:23 +10:00
Dion Moult
9a59b8cdae
Material psets now include category-specific psets and docstrings
...
Previously it was not possible to get concrete / steel material psets. Yikes!
2024-05-26 11:23:08 +10:00
Andrej730
f576aadee1
typing
2024-05-24 19:15:51 +05:00
Andrej730
073e471305
typing
2024-05-23 18:45:30 +05:00
Dion Moult
02cae9c7c2
Continue to revise optimisation of remove_deep to fix failing tests after a8729933
2024-05-23 22:54:19 +10:00
Dion Moult
a8729933af
Optimise remove_deep, which can make removing lots of elements 100x faster in scripts.
2024-05-23 20:15:09 +10:00
Andrej730
f2eb08a066
typing
2024-05-22 17:43:05 +05:00
Andrej730
f460676e54
fix calculating cost summary #4704 (was confusing 0 qty and no qty)
...
similar to 295d0a677
2024-05-22 17:37:32 +05:00
Dion Moult
69c197c1a4
get_psets utility now defaults to merging duplicate psets instead of overriding
...
This behaviour is more comprehensive for broken data and now consistent for types and materials.
2024-05-22 08:12:38 +10:00
Andrej730
295d0a677e
cost schedule - prohibit adding multiple quantity types on 1 cost item
...
All IfcCostItem.CostQuantities supposed to use only 1 type of quantity, so they can be added up.
Changed UI to reflect that requirement - dropdown for selecting quantity type is now only visible if cost item has no quantities, otherwise it just reuses already used quantity type.
See https://ifc43-docs.standards.buildingsmart.org/IFC/RELEASE/IFC4x3/HTML/lexical/IfcCostItem.htm
Before - https://i.imgur.com/gFlwHEk.png
After - https://i.imgur.com/pk3wXfe.png
2024-05-21 17:54:07 +05:00
Andrej730
9aacafd575
fix bug with cost schedules confusing 0 quantity with no quantities
...
a bit related to #4704
1) fixed util.cost.get_total_quantity
2) fixed similar issue in cost.data that calculates the final value that user will see in UI
3) changed UI, "-" is shown when there are no quantities and "0" is when quantities are there but they just equal to zero.
Before - https://i.imgur.com/EO53DhM.png
After - https://i.imgur.com/H6rK4sP.png
fyi @myoualid
2024-05-21 17:54:07 +05:00
Andrej730
d064ef1237
black format
2024-05-21 17:53:46 +05:00
Andrej730
221dd9a7a2
typing
2024-05-21 17:53:42 +05:00
Andrej730
a8f0c90d47
set_element_value - fix issues with classification, similar to 52ae759
2024-05-17 17:31:01 +05:00
Andrej730
39f550529b
experimental - set_element_value to throw exception for invalid queries
2024-05-17 17:31:01 +05:00
Andrej730
25c1a14e64
set_element_value - pass attr value to the next part of the query #4495
...
E.g. previously set_element_value with query "material.item.Material.Name" would fail with error "Material property is expecting an IFC entity and not a string".
But now it will detect that "Material" property is not a last key in the query and will pass `.Material` value forward and try to set it's `.Name` attribute with value.
The main goal is to make sure get_element_value and set_element_value would have a same result for same queries.
2024-05-17 17:31:01 +05:00
Andrej730
9f7d710119
fix set_element_value bug #4495
2024-05-17 17:31:01 +05:00
Andrej730
ea592775e4
fix set_element_value setting bool attributes with "False" str value
2024-05-17 17:31:01 +05:00
Andrej730
42be4eb064
typing
2024-05-17 17:31:01 +05:00
Andrej730
3884403231
typing
2024-05-16 18:14:06 +05:00
Andrej730
bb8e84e5ec
typing
2024-05-15 17:18:33 +05:00
Andrej730
ebd03e9290
typing
2024-05-13 18:01:17 +05:00
Dion Moult
b7737cb6d3
Fix #4655 . profiles is now available as a keyword in the selector syntax.
2024-05-11 22:57:16 +10:00
Dion Moult
6df6553935
Notify user if duration parsing not available in util.date
2024-05-11 15:14:39 +10:00
Andrej730
845d772a08
move sequence.get_related_products to util module
2024-05-10 19:18:09 +05:00
Andrej730
1e630ede08
ifc2x3 tests
2024-05-10 19:18:09 +05:00
Andrej730
2d35869c41
typing
2024-05-09 18:00:17 +05:00
Dion Moult
d453adb7cf
Forgot to commit IfcTester fix for missing failed entities
2024-05-09 10:36:39 +10:00
Andrej730
cbf04546b8
fix many implicit ifcopenshell.guid imports
...
a bit related to 10d30b0de
2024-05-08 18:18:02 +05:00
Dion Moult
93639e9e50
Even more cleaning of documentation references
2024-05-07 19:08:13 +10:00
Dion Moult
d76462ca42
Write more documentation
...
Sphinx autoapi also now only shows subpackages 1 level deep. This prevents us having a huge long list. Also don't show private or special members. Also show imported members so ifcopenshell.file and ifcopenshell.entity_instance works in docs too.
2024-05-07 17:32:47 +10:00
Dion Moult
424a06f6c8
More cleaning up of forward type hints to fix import errors
2024-05-07 14:58:12 +10:00
Dion Moult
89c4cbeb05
Drop support for Python 2.
2024-05-07 12:17:46 +10:00
Dion Moult
7e13ed746e
Don't rely on util for basic ifcopenshell module capabilities. Keep util as an optional module for users to load.
2024-05-07 10:32:02 +10:00
Andrej730
8dde98f543
fix #4592 (after 0da3270)
...
Before IFC4 Shape Aspects counldn't be part of IfcRepresentationMap
2024-04-29 15:22:26 +05:00
Andrej730
640320f70d
shape_builder - create non-optional position for profiles in ifc2x3
2024-04-25 18:05:47 +05:00
Andrej730
5b877b549a
fix numpy typing #4579
...
On older numpy versions, np.ndarray was less forgiving and wasn't allowing passing 1 argument instead of required 2.
And turned out numpy doesn't yet have typing for shapes (https://github.com/numpy/numpy/issues/16544 ), so all matrices and other shapes specified as `npt.NDArray[np.float64]`.
Fixed type discrepancies for `get_edges` and `get_faces` and also had to fix `import_ifc` as Blender apparently has problems with storing np.int32 in custom attributes (https://projects.blender.org/blender/blender/issues/121072 ), tested that Blender is okay with np.int32 in other cases we had (addressing BMesh.verts[i] where `i` is np.int32).
2024-04-25 18:05:47 +05:00
Andrej730
721466c429
typing
2024-04-25 18:05:47 +05:00
Andrej730
f1037de14d
small fix for 60a70f523
2024-04-25 18:05:46 +05:00