Archipack 1.3.8 - 18.04.2018

stephen_leger

Hi serviteur,
Thank you for your feed back, hope you are finally able to get polylib working.

Wall from spline allredy in the pipe, so anything you may convert to a 2d spline may work.
Converting draft volumes to walls like you may do in revit may be possible, but not to be expected soon.

Currently working on snap feature to create and modify wall.

I have not solved the problem with 2d polygons.

Thread on ubuntu forum (french): https://forum.ubuntu-fr.org/viewtopic.php?id=2008886

command is : /usr/bin/python3.5 no /usr/lib/python3.5/

serviteur @ HP-EliteBook-8760w  ~
└─ $ β–Ά sudo /usr/bin/python3.5 -m pip install shapely
[sudo] Mot de passe de serviteur : 
The directory '/home/serviteur/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/serviteur/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting shapely
  Downloading Shapely-1.5.17.post1-cp35-cp35m-manylinux1_x86_64.whl (8.3MB)
    100% |β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 8.3MB 16kB/s 
Installing collected packages: shapely
Successfully installed shapely-1.5.17.post1
You are using pip version 8.1.1, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
serviteur @ HP-EliteBook-8760w  ~
└─ $ β–Ά 

After installation:

>> from shapely import geometry
Traceback (most recent call last):
  File "<blender_console>", line 1, in <module>
ImportError: No module named 'shapely'



>>> import sys
>>> sys.path
['/opt/blender/2.78/scripts/addons_contrib', '/home/serviteur/.config/blender/2.78/scripts/addons', '/opt/blender/2.78/scripts/addons', '/opt/blender/2.78/scripts/startup', '/opt/blender/2.78/scripts/modules', '/opt/blender/2.78/python/lib/python35.zip', '/opt/blender/2.78/python/lib/python3.5', '/opt/blender/2.78/python/lib/python3.5/plat-linux', '/opt/blender/2.78/python/lib/python3.5/lib-dynload', '/opt/blender/2.78/python/lib/python3.5/site-packages', '/opt/blender/2.78/scripts/freestyle/modules', '/opt/blender/2.78/scripts/addons/modules', '/home/serviteur/.config/blender/2.78/scripts/addons/modules']

>>>

As I can see you installed Shapely into Systems python, but Blender it is using his own internal Python who can’t read the Shapely module installed in your system.

$ :arrow_forward: sudo /usr/bin/python3.5 -m pip install shapely

So you have Shapely in β€œ/usr/bin/python3.5”

β€˜/opt/blender/2.78/python/lib/python3.5’,

and Blender is accessing his internal version of Python located here!

Please read very carefully the articles I pointed to on my previous post. There it is describing how to solve this issue.

artisanicview

So you have Shapely in β€œ/usr/bin/python3.5”

β€˜/opt/blender/2.78/python/lib/python3.5’,

and Blender is accessing his internal version of Python located here!

Please read very carefully the articles I pointed to on my previous post. There it is describing how to solve this issue.

Your previous post is #19 or #37 ?

serviteur @ HP-EliteBook-8760w  ~
└─ $ β–Ά sudo /opt/blender/2.78/python/lib/python3.5/python3.5 -m pip install shapely
[sudo] Mot de passe de serviteur : 
sudo: /opt/blender/2.78/python/lib/python3.5/python3.5 : commande introuvable
serviteur @ HP-EliteBook-8760w  ~
└─ $ β–Ά

serviteur @ HP-EliteBook-8760w  ~
└─ $ β–Ά sudo /opt/blender/2.78/python/lib/python3.5/python -m pip install shapelysudo: /opt/blender/2.78/python/lib/python3.5/python : commande introuvable
serviteur @ HP-EliteBook-8760w  ~
└─ $ β–Ά 

Post number 37

artisanicview
Post number 37

Your python console it is not showing as Blender is using the systems Python 3.5 installation. Seems that your Blender is using the bundled version of python that comes with Blender.

According to this post, you will need to download and use a buildbot version of Blender.

Seems that on Linux the things are a little bit different than I expected. I’m mostly a MAC user and for me was very easy to force Blender to use Python 3.5.2 that I have installed on my system.

Some more possible answers:

How about a linux replacing bundled python

How to use PIP with Blender’s bundled Python?

I did not understand how to do in both links (below), if possible please help me. Thank you

1- https://community.gamedev.tv/t/how-about-a-linux- replacing-bundled-python/10190/5

2-
https://blender.stackexchange.com/questions/56011/how-to-use-pip-with-blenders-bundled-python

OMG!
Just best archiCAD-like slution for now
We know Prokitektura, Archimesh, other addons, but this make mode sense as i see.
Hope will have time for tests.

I’m deeply, essentialy impressed with your research.
This is just incredible!

Haha! Marvellous!

@ Hi stephen_leger

Setup shapely under ubuntu

Under ubuntu (tested under 16.10) Blender 2.77-2.78 should use the python 3.5 built on the system.

How you installed Blender 277 or 2.78c on Ubuntu 16.10 ?

Using OpenDroneMap based ubuntu, setup blender with standard tool. Maybe they setup a path to get more recent blender than ubuntu.

stephen_leger
Using OpenDroneMap based ubuntu, setup blender with standard tool. Maybe they setup a path to get more recent blender than ubuntu.

I first installed Blender manually (Xubuntu) by this link:

I have uninstalled all manual installation.

I made a new installation by PPA:

sudo add-apt-repository ppa:thomas-schiex/blender

sys.path

>>> import sys
>>> sys.path
['/usr/share/blender/2.78/scripts/addons_contrib', '/usr/share/blender/2.78/scripts/addons', '/usr/share/blender/2.78/scripts/startup', '/usr/share/blender/2.78/scripts/modules', '/usr/lib/python35.zip', '/usr/lib/python3.5', '/usr/lib/python3.5/plat-x86_64-linux-gnu', '/usr/lib/python3.5/lib-dynload', '/usr/local/lib/python3.5/dist-packages', '/usr/lib/python3/dist-packages', '/usr/share/blender/2.78/scripts/freestyle/modules', '/usr/share/blender/2.78/scripts/addons/modules', '/home/serviteur/.config/blender/2.78/scripts/addons/modules']


Setup shapely

serviteur @ HP-EliteBook-8760w  ~
└─ $ β–Ά sudo /usr/lib/python3.5 -m pip install shapely
[sudo] Mot de passe de serviteur : 
sudo: /usr/lib/python3.5 : commande introuvable
serviteur @ HP-EliteBook-8760w  ~
└─ $ β–Ά 

serviteur @ HP-EliteBook-8760w  ~
└─ $ β–Ά sudo /usr/lib/python3.5/python3.5 -m pip install shapely
sudo: /usr/lib/python3.5/python3.5 : commande introuvable
serviteur @ HP-EliteBook-8760w  ~
└─ $ β–Ά 




serviteur @ HP-EliteBook-8760w  ~
└─ $ β–Ά sudo /usr/local/lib/python3.5/python3.5 -m pip install shapely
[sudo] Mot de passe de serviteur : 
sudo: /usr/local/lib/python3.5/python3.5 : commande introuvable
serviteur @ HP-EliteBook-8760w  ~
└─ $ β–Ά sudo /usr/local/lib/python3.5/ -m pip install shapely
sudo: /usr/local/lib/python3.5/ : commande introuvable
serviteur @ HP-EliteBook-8760w  ~
└─ $ β–Ά sudo /usr/local/lib/python3.5 -m pip install shapely
sudo: /usr/local/lib/python3.5 : commande introuvable
serviteur @ HP-EliteBook-8760w  ~
└─ $ β–Ά

commande introuvable= command not found

Any path dones not work.

β€˜β€™ Excuses me for my bad English, I’m French’'

Download official Blender tar.bz2 file for Linux (32 or 64 bits depending on the architecture of your installed system):

From your file browser extract the content of tar.bz2 file to new folder. Enter to the folder and execute (double click) β€˜blender’ file.

Just seen this new video on youtube:

Oops, i forget to mention here.
Yes, it’s a somewhat hidden feature of archipack : allow quick and easy 2d to 3d.
(this is the part of archipack requiring shapely to work)
Please do note that ui is likely to be improved soon.

@serviteur.
I am doing this in Kubuntu 16.04:

sudo apt-get install python3-pip

Now being connected to the internet I install shapely for the user (without sudo):

python3.5 -m pip install shapely

But now if I open Official Blender 2.78c and in python console I type β€œfrom shapely import geometry”, then it does not find libgeos. I really do not know if libgeos is needed for the addon, or it’s just a shapely installation test. Just in case I install libgeos. I installed these two packages:

sudo apt install libgeos-c1v5 libgeos-dev

So now it seems to work.

One clarification, you notice that I am using official Blender, that is, without it being installed on the system. I am not sure about whether you use Blender installed on the system from some repository, then you would need to install shapely on the system also with β€œsudo”. Anyway, it is always recommended to use official Blender.

Edit:
Before doing what I have explained, it may be appropriate to remove any previous shapely installation that you have made. Delete shapely related folders in: β€œ/usr/lib/python3/dist-packages” (Maybe there is some uninstall command, but I do not know). Also maybe uninstall packages related to shapely if you installed any of them

Edit 2:
In Kubuntu 14.04 the above mentioned command does not let me install shapely without sudo, so I install it with:

python3.5 -m pip install shapely --user

(which may be it is the convenient way to do it)

Edit 3:
As you may have guessed, this also did not work for me with β€œsudo /usr/lib/python3.5/python3.5 -m pip install shapely” as it is mentioned in the wiki, Ubuntu does not install the binary in that path. Because that i just use β€œpython3.5 -m pip install”, (and maybe it can work also with β€œpip3 install”).

I have no idea about python, just researching and testing

@stephen_leger: I just found a video demonstrating how to build wooden structures in LWCAD, maybe you can find some ideeas for your upcoming roof generator:

and

Yes, Shapely needs Libgeos to work properly. In Linux you need to manually install that library.

YAFU

Now being connected to the internet I install shapely for the user (without sudo):
Code:
python3.5 -m pip install shapely

Thanks you YAFU.

serviteur @ HP-EliteBook-8760w  ~
└─ $ β–Ά python3.5 -m pip install shapely
Collecting shapely
  Downloading Shapely-1.5.17.post1-cp35-cp35m-manylinux1_x86_64.whl (8.3MB)
    100% |β–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆβ–ˆ| 8.3MB 13kB/s 
Installing collected packages: shapely
Successfully installed shapely-1.5.17.post1
You are using pip version 8.1.1, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
serviteur @ HP-EliteBook-8760w  ~
└─ $ β–Ά 

from shapely import geometry

>>> from shapely import geometry
>>> 

Archipack 2d don’t work with Mesh


Archipack 2d work, Convert to: Curve from Mesh/text


So now it seems to work.

One clarification, you notice that I am using official Blender, that is, without it being installed on the system. I am not sure about whether you use Blender installed on the system from some repository, then you would need to install shapely on the system also with β€œsudo”. Anyway, it is always recommended to use official Blender.

I am using the PPA:

sudo add-apt-repository ppa:thomas-schiex/blender

So if you install Shapely locally for user (without sudo) then it works fine in Blender installed from repository? That is good!
I had the doubt about it because installing Shapely with sudo, then it did not work in official Blender (Blender can not find it).

Ok, thanks.

@ stephen_leger

Thanks for update.

How to use:

  • Draw a Wall
  • Fence curve