Nice progress Shiv, keep going!Shiv_Charan wrote: ↑Sun Jul 11, 2021 4:07 pm Implementation of UI to make slab Reinforcement is complete, including suggestions related to removing separate tabs for parallel/cross distribution rebars as discussed in meeting.
here is the merge request : https://github.com/amrit3701/FreeCAD-Re ... t/pull/158
Implementation of rebar grouping and edit slab reinforcement in progress and will be complete soon.
here are some sample UI input and output:
I will also create separate documentation for it once the edit part is done.
GSoC Proposal: Automate Reinforcement Process of Slab and Footing in FreeCAD
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Be nice to others! Respect the FreeCAD code of conduct!
Re: GSoC Proposal: Automate Reinforcement Process of Slab and Footing in FreeCAD
-
- Posts: 59
- Joined: Wed Mar 03, 2021 12:10 pm
Re: GSoC Proposal: Automate Reinforcement Process of Slab and Footing in FreeCAD
Thank you @amrit3701
Regards
Shiv Charan
https://github.com/ShivCharanSharma
https://github.com/ShivCharanSharma
-
- Posts: 59
- Joined: Wed Mar 03, 2021 12:10 pm
Re: GSoC Proposal: Automate Reinforcement Process of Slab and Footing in FreeCAD
Hi @amrit3701
here is merge request : https://github.com/amrit3701/FreeCAD-Re ... t/pull/159
Now user can change properties from property panel and changes will reflect in Slab Reinforcement simultaneously.
For example : -
1. Initial Slab Reinforcement:
2. changing cross rebar type from bent shape to L-shape from properties panel:-
3. Output after changing rebar type in slab reinforcement ( Now Slab have L-Shpae rebars in cross) :-
Thanks and Regards
Implementation of rebar grouping and edit slab reinforcement through properties panel is done.Shiv_Charan wrote: ↑Sun Jul 11, 2021 4:07 pm
Implementation of rebar grouping and edit slab reinforcement in progress and will be complete soon.
here is merge request : https://github.com/amrit3701/FreeCAD-Re ... t/pull/159
Now user can change properties from property panel and changes will reflect in Slab Reinforcement simultaneously.
For example : -
1. Initial Slab Reinforcement:
2. changing cross rebar type from bent shape to L-shape from properties panel:-
3. Output after changing rebar type in slab reinforcement ( Now Slab have L-Shpae rebars in cross) :-
Thanks and Regards
Shiv Charan
https://github.com/ShivCharanSharma
https://github.com/ShivCharanSharma
-
- Posts: 59
- Joined: Wed Mar 03, 2021 12:10 pm
Re: GSoC Proposal: Automate Reinforcement Process of Slab and Footing in FreeCAD
Hi @amrit3701
Implementation to edit Slab Reinforcement through QT window and Python api is also done:
here is the merge request : https://github.com/amrit3701/FreeCAD-Re ... t/pull/161
Now user has three method to edit slab reinforcement:
Steps to edit slab reinforcement through QT window:-
1. create slab reinforcement by python api or GUI
2. double click on SlabReinforcement group ( It will open edit GUI for slab reinforcement)
3. edit values in GUI click on finish.
Now changes will reflect in Reinforcement.
For example:-
1. initial slab reinforcement: having straight rebars in parallel and bent shpae in cross with distribution rebars.
2. double click on SlabReinforcement object in tree view.
3. A edit GUI will pop up change value in GUI as per your need:-
4. click on finish.
output after above chages:
Working of edit python API :-
For example :-
1. created slab reinforcement using following script on given file : -
Slab Reinforcement creation script for slab having bent shape on both side with distribution rebars:-
output :
Now you can edit above slab reinforcement by using editSlabReinforcement python api of SlabReinforcement.
pass slabReinforcementGroup return by above script to editSlabReinforcement api as following script
Script to edit above slab reinforcement
( here we are modifying rebar amount for cross and parallel but you can modify any parameter )
output after edit:
Thanks and Regards
Implementation to edit Slab Reinforcement through QT window and Python api is also done:
here is the merge request : https://github.com/amrit3701/FreeCAD-Re ... t/pull/161
Now user has three method to edit slab reinforcement:
- By python api
- By QT window ( similar to GUI for creating slab reinforcement)
- By properties panel (as discussed in previous post)
Steps to edit slab reinforcement through QT window:-
1. create slab reinforcement by python api or GUI
2. double click on SlabReinforcement group ( It will open edit GUI for slab reinforcement)
3. edit values in GUI click on finish.
Now changes will reflect in Reinforcement.
For example:-
1. initial slab reinforcement: having straight rebars in parallel and bent shpae in cross with distribution rebars.
2. double click on SlabReinforcement object in tree view.
3. A edit GUI will pop up change value in GUI as per your need:-
4. click on finish.
output after above chages:
Working of edit python API :-
For example :-
1. created slab reinforcement using following script on given file : -
Slab Reinforcement creation script for slab having bent shape on both side with distribution rebars:-
Code: Select all
from SlabReinforcement import SlabReinforcement
import importlib
importlib.reload(SlabReinforcement)
slabReinforcementGroup = SlabReinforcement.makeSlabReinforcement(
parallel_rebar_type="BentShapeRebar",
parallel_front_cover=20,
parallel_rear_cover=20,
parallel_left_cover=10,
parallel_right_cover=10,
parallel_top_cover=30,
parallel_bottom_cover=20,
parallel_diameter=8,
parallel_amount_spacing_check=True,
parallel_amount_spacing_value=10,
parallel_rounding=2,
parallel_bent_bar_length=150,
parallel_bent_bar_angle=135,
cross_rebar_type="BentShapeRebar",
cross_front_cover=20,
cross_rear_cover=20,
cross_left_cover=10,
cross_right_cover=10,
cross_top_cover=29,
cross_bottom_cover=20,
cross_diameter=8,
cross_amount_spacing_check=True,
cross_amount_spacing_value=10,
cross_rounding=2,
cross_bent_bar_length=150,
cross_bent_bar_angle=135,
mesh_cover_along="Bottom",
structure=App.getDocument("slab").getObject("Beam"),
facename='Face4',
parallel_distribution_rebars_check= True,
parallel_distribution_rebars_diameter=8,
parallel_distribution_rebars_amount_spacing_check= True,
parallel_distribution_rebars_amount_spacing_value= 6,
cross_distribution_rebars_check = True,
cross_distribution_rebars_diameter=8,
cross_distribution_rebars_amount_spacing_check=False,
cross_distribution_rebars_amount_spacing_value = 40,
)
pass slabReinforcementGroup return by above script to editSlabReinforcement api as following script
Script to edit above slab reinforcement
( here we are modifying rebar amount for cross and parallel but you can modify any parameter )
Code: Select all
slabReinforcementGroup = SlabReinforcement.editSlabReinforcement(
slabReinforcementGroup,
parallel_rebar_type="BentShapeRebar",
parallel_front_cover=20,
parallel_rear_cover=20,
parallel_left_cover=10,
parallel_right_cover=10,
parallel_top_cover=30,
parallel_bottom_cover=20,
parallel_diameter=8,
parallel_amount_spacing_check=True,
parallel_amount_spacing_value=5,
parallel_rounding=2,
parallel_bent_bar_length=150,
parallel_bent_bar_angle=135,
cross_rebar_type="BentShapeRebar",
cross_front_cover=20,
cross_rear_cover=20,
cross_left_cover=10,
cross_right_cover=10,
cross_top_cover=29,
cross_bottom_cover=20,
cross_diameter=8,
cross_amount_spacing_check=True,
cross_amount_spacing_value=5,
cross_rounding=2,
cross_bent_bar_length=150,
cross_bent_bar_angle=135,
mesh_cover_along="Bottom",
structure=App.getDocument("slab").getObject("Beam"),
facename='Face4',
parallel_distribution_rebars_check= True,
parallel_distribution_rebars_diameter=8,
parallel_distribution_rebars_amount_spacing_check= True,
parallel_distribution_rebars_amount_spacing_value= 6,
cross_distribution_rebars_check = True,
cross_distribution_rebars_diameter=8,
cross_distribution_rebars_amount_spacing_check=False,
cross_distribution_rebars_amount_spacing_value = 40,
)
Shiv Charan
https://github.com/ShivCharanSharma
https://github.com/ShivCharanSharma
Re: GSoC Proposal: Automate Reinforcement Process of Slab and Footing in FreeCAD
Hi Shiv_Charan, I want to check out your work and possible help you with the UI. Where can I find your latest version? Or do I have to wait till everything is merged?
nvm, got it. I downloaded your latest branch, https://github.com/ShivCharanSharma/Fre ... dit-UI/API
Now I got this error when using you gui to generate reinforcement for a slab:
nvm, got it. I downloaded your latest branch, https://github.com/ShivCharanSharma/Fre ... dit-UI/API
Now I got this error when using you gui to generate reinforcement for a slab:
Code: Select all
18:42:55 Traceback (most recent call last):
File "C:\Users\marce\AppData\Roaming\FreeCAD\Mod\Reinforcement\SlabReinforcement\SlabReinforcementObject.py", line 775, in onChanged
self.makeOrEditSlabReinforcement(obj)
File "C:\Users\marce\AppData\Roaming\FreeCAD\Mod\Reinforcement\SlabReinforcement\SlabReinforcementObject.py", line 943, in makeOrEditSlabReinforcement
cross_facename = getFacenamesforBeamReinforcement(facename, structure)[
File "C:\Users\marce\AppData\Roaming\FreeCAD\Mod\Reinforcement\Rebarfunc.py", line 722, in getFacenamesforBeamReinforcement
return facename_for_tb_rebars, facename_for_s_rebars
<class 'UnboundLocalError'>: local variable 'facename_for_tb_rebars' referenced before assignment
-
- Posts: 59
- Joined: Wed Mar 03, 2021 12:10 pm
Re: GSoC Proposal: Automate Reinforcement Process of Slab and Footing in FreeCAD
Hi @Meetlat,Meetlat wrote: ↑Fri Jul 16, 2021 12:30 pm
Now I got this error when using you gui to generate reinforcement for a slab:
Code: Select all
18:42:55 Traceback (most recent call last): File "C:\Users\marce\AppData\Roaming\FreeCAD\Mod\Reinforcement\SlabReinforcement\SlabReinforcementObject.py", line 775, in onChanged self.makeOrEditSlabReinforcement(obj) File "C:\Users\marce\AppData\Roaming\FreeCAD\Mod\Reinforcement\SlabReinforcement\SlabReinforcementObject.py", line 943, in makeOrEditSlabReinforcement cross_facename = getFacenamesforBeamReinforcement(facename, structure)[ File "C:\Users\marce\AppData\Roaming\FreeCAD\Mod\Reinforcement\Rebarfunc.py", line 722, in getFacenamesforBeamReinforcement return facename_for_tb_rebars, facename_for_s_rebars <class 'UnboundLocalError'>: local variable 'facename_for_tb_rebars' referenced before assignment
Thanks for testing slab reinforcement.
I am looking into it and trying to find cause of it.
Any pointer to regenerate the error or providing sample freeCAD file that your are using, will be highly appreciated and will help me a lot to debug the issue.
Thanks and Regards
Shiv Charan
https://github.com/ShivCharanSharma
https://github.com/ShivCharanSharma
Re: GSoC Proposal: Automate Reinforcement Process of Slab and Footing in FreeCAD
I do nothing special. I think it's due to using a corrupted branch. Where can I find a working branch of your modified Reinforcement workbench?
-
- Posts: 59
- Joined: Wed Mar 03, 2021 12:10 pm
Re: GSoC Proposal: Automate Reinforcement Process of Slab and Footing in FreeCAD
Hi @Meetlat,
This is latest branch.
Are you using non rectangular slab ?
Slab reinforcement work with rectangular slab like structure.
Can you try slab reinforcement with following file or similar?
Thanks for your efforts.
Regards
Shiv Charan
https://github.com/ShivCharanSharma
https://github.com/ShivCharanSharma
Re: GSoC Proposal: Automate Reinforcement Process of Slab and Footing in FreeCAD
Hey Shiv,
How is your progress going with the footings structure element?
Can you please post your updates here? I haven't seen any activity on Github? I would suggest to regularly push your code and make smaller PR's.
-
- Posts: 59
- Joined: Wed Mar 03, 2021 12:10 pm
Re: GSoC Proposal: Automate Reinforcement Process of Slab and Footing in FreeCAD
Hi @amrit3701,
I have created a merge request related to some improvements in slab reinforcement and also added icon for Slab Reinforcement.
here is merge request : https://github.com/amrit3701/FreeCAD-Re ... t/pull/162
The Icon that I have added is here :
I am working on footing reinforcement and will push the code soon.
I have also added documentation for slab reinforcement.
link to documentation is here : https://wiki.freecadweb.org/Arch_Rebar_ ... nforcement
And documnetation of some of examples are here :
=== Examples for Slab Reinforcement===
Slab Spanning in Two Directions
https://wiki.freecadweb.org/Example_Sla ... Directions
Slab Spanning in One Direction:-
https://wiki.freecadweb.org/Example_Sla ... _Direction
Slab Having Straight Rebars Reinforcement Mesh:-
https://wiki.freecadweb.org/Example_Sla ... ght_Rebars
Slab Having U-Shape Rebars Reinforcement Mesh:-
https://wiki.freecadweb.org/Example_Sla ... ement_Mesh
Slab Having L-Shape Rebars Reinforcement Mesh:-
https://wiki.freecadweb.org/Example_Sla ... ement_Mesh
Thanks and Regards
Shiv Charan
https://github.com/ShivCharanSharma
https://github.com/ShivCharanSharma