gumyr / bd_warehouse Goto Github PK
View Code? Open in Web Editor NEWA build123d parametric part collection
License: Apache License 2.0
A build123d parametric part collection
License: Apache License 2.0
From bernhard:
md = 20 * MM
p = 3.5 * MM
l = 6 * MM
iso_external = IsoThread(
major_diameter=md,
pitch=p,
length=l,
external=True,
end_finishes=("fade", "fade"),
hand="right",
)
show(iso_external)
yeah, it is in _make_fade_end. Currently it uses Plane.XZ for internal and external, but it looks like for external we need Plane.ZY
found by trial and error, not sure it is the right fix though
This seems to work when I pass the external parameter into the Thread init function
But, as I said, can't judge whether this is the root cause or whether it is generically correct.
A Piping Component File (PCF) is a type of file format used in the field of piping design and engineering. It is a standardized format for exchanging data related to piping components between different piping design software applications.
A PCF file contains information about various piping components, such as pipes, fittings, valves, flanges, and other related items. It includes details like dimensions, material specifications, ratings, connections, and other relevant attributes of the components.
The purpose of the PCF format is to enable interoperability and seamless data exchange between different software systems used in the piping industry. It allows piping designers and engineers to transfer component data accurately and efficiently, reducing the need for manual data entry or re-creation of components in different software platforms.
PCF files are typically generated by piping design software applications and can be imported or exported to exchange data between different software packages involved in the piping design and analysis process. This facilitates collaboration, consistency, and accuracy in piping projects by ensuring that all stakeholders have access to consistent and up-to-date component information.
The PCF (Piping Component File) format is defined and maintained by the Process Industry Practices (PIP) organization. PIP is a consortium of process industry owners and engineering construction contractors dedicated to promoting common practices and standards in the industry.
The PIP organization has developed a set of guidelines and specifications for various aspects of the process industry, including piping design and engineering. The PIP PCF Specification (PIP PNSM0001) provides detailed information on the structure, content, and formatting of PCF files.
The PIP PCF Specification defines the file format, including the syntax, data fields, and conventions used in PCF files. It specifies the required and optional data elements, the supported data types, and the recommended practices for generating and interpreting PCF files.
While PIP maintains and updates the PCF specification, it is important to note that there may be variations or extensions of the PCF format implemented by different software vendors. Therefore, it is essential to refer to the specific documentation and guidelines provided by the software application or system that utilizes PCF files to ensure compatibility and proper usage.
Have not checked other thread types
Once threads have been ported from cq_warehouse, add a ThreadedFlange.
one doesn't need to pass external to Thread. It is derived there anyhow
ref = Cylinder(1, 1, align=(Align.CENTER, Align.CENTER, Align.MIN))
fade = Pos(2.5) * TrapezoidalThread(2, 0.5, 20, 1, end_finishes=("fade", "fade"))
square = Pos(5) * TrapezoidalThread(2, 0.5, 20, 1, end_finishes=("square", "square"))
chamfer = Pos(7.5) * TrapezoidalThread(2, 0.5, 20, 1, end_finishes=("chamfer", "chamfer"))
raw = Pos(10) * TrapezoidalThread(2, 0.5, 20, 1, end_finishes=("raw", "raw"))
It seems that bottom_loop.intersect(chamfer_shape)
creates a zero-volume object and is dropped as a result of the following volume check.
I've been unable to trace the root cause further.
bd_warehouse/src/bd_warehouse/thread.py
Line 214 in 67e697a
Currently only raised and ring faces are supported. Add the other types like tongue and groove, etc.
right = IsoThread(
major_diameter=VF_thread_major_diameter,
pitch=VF_thread_pitch,
length=VF_inlet_thread_length,
hand="right",
external=True,
end_finishes=("chamfer", "chamfer"),
align=(
bd.Align.CENTER,
bd.Align.CENTER,
bd.Align.MIN,
),
)
right.label = 'right'
left = IsoThread(
major_diameter=VF_thread_major_diameter,
pitch=VF_thread_pitch,
length=VF_inlet_thread_length,
hand="left",
external=True,
end_finishes=("chamfer", "chamfer"),
align=(
bd.Align.CENTER,
bd.Align.CENTER,
bd.Align.MAX,
),
)
left.label = 'left'
show(right,left)
# IsoThread external in the form of a screw
iso_external = IsoThread(
major_diameter=6 * MM,
pitch=1 * MM,
length=4.5 * MM,
external=True,
end_finishes=("square", "square"),
hand="right",
)
external_core = Cylinder(
iso_external.root_radius,
iso_external.length,
align=(Align.CENTER, Align.CENTER, Align.MIN),
)
iso_external_screw = iso_external.fuse(external_core)
show_object(iso_external_screw.locate(Location((10, 10, 0))))
Using any variation of the following code results in the AttributeError in the title.
test = MetricTrapezoidalThread(size="32x3", length=50.0, external=True)
The flange and pipe examples shown in the docs work fine. I can provide additional information if it would be helpful.
After installing according to the installation guide in the documentation, when trying to import from bd_warehouse.fastener
, I get the error message: ModuleNotFoundError: No module named 'importlib_resources'
. Here's a more detailed log from the Jupyter notebook:
File ~/<Project Path>/.venv/lib/python3.11/site-packages/bd_warehouse/fastener.py:44
41 from typing import Literal, Optional, Union
43 import bd_warehouse
---> 44 import importlib_resources
45 from bd_warehouse.thread import IsoThread, imperial_str_to_float, is_safe
46 from build123d.build_common import (
47 IN,
48 MM,
(...)
52 validate_inputs,
53 )
ModuleNotFoundError: No module named 'importlib_resources'
I'm running on fully updated Arch Linux using Python 3.11.8.
When creating a bill of materials from a complex pipe each segment should be individually accessible. In addition, to enable space for welds, a carbon steel pipe segments would have a 1/16" gap between them (while the gap for stainless is 0").
To achieve this:
path
needs to be stored in an instance variable such that the Edges can be extracted from the path.TrapezoidalThread(2, 0.5, 20, 1, end_finishes=("fade", "fade")).center()
TrapezoidalThread(2, 0.5, 20, 1, end_finishes=("chamfer", "chamfer")).center()
TrapezoidalThread(2, 0.5, 20, 1, end_finishes=("raw", "raw")).center()
TrapezoidalThread(2, 0.5, 20, 1, end_finishes=("square", "square")).center() # <---- ERROR
AttributeError: 'TrapezoidalThread' object has no attribute 'IsNull'. Did you mean: 'is_null'?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.