@arch_shovel · Post #548 · 02.08.2022 г., 19:19
Zeeland. Visualization by WSBY #arch_shovel#archdaily
Hashtags
TGINSIGHT SIMILAR POSTS
Изворен канал @pythonotes · Post #32 · 7 фев.
Скорее всего уже слышали, что складывать строки через + это плохая практика. Падение производительности, и всё такое. Без лишних слов, давайте измерять: from timeit import timeit def t1(): # складываем 10 строк через + из переменной t = 'text' for _ in range(1000): s = t + t + t + t + t + t + t + t + t def t2(): # склеиваем список строк через метод join arr = ['text'] * 10 for _ in range(1000): s = ''.join(arr) def t3(): # складываем через + но не из переменной а непосредственно инлайн объекты for _ in range(1000): s = 'text' + 'text' + 'text' + ... # всего 10 раз Теперь каждую строку склейки запустим по 10М раз >>> timeit(t1, number=10000) 0.21951690399964718 >>> timeit(t2, number=10000) 1.4978306379998685 >>> timeit(t3, number=10000) 0.2213820789993406 Хм, а нам говорили что через "+" это плохо и медленно ))) 😁 Тут стоит учитывать, что речь идёт о склейке множества длинных строк. Давайте изменим условия: def t4(): t = 'text'*100 for _ in range(1000): s = t + t + t + t + t + t + t + t + t def t5(): arr = ['text'*100] * 10 for _ in range(1000): s = ''.join(arr) def t6(): for _ in range(1000): s = 'text'*100 + 'text'*100 + ... # всего 10 раз >>> timeit(t4, number=10000) 12.795130728000004 >>> timeit(t5, number=10000) 2.642637542999182 >>> timeit(t6, number=10000) 0.2184546610005782 Вот, уже другой разговор, сразу видна разница, в среднем в 6 раз. Но погодите, почему последний тест t6() по скорости такой же как и t3()? Ведь строки теперь в 100 раз длиннее! Это вопросы оптимизации кода, какие простые изменения ускоряют или замедляют выполнение программы. Мы столкнулись с примером обхода обращения к переменной. Например, именно так работает директива #define в С++, во время компиляции подставляя значение переменной вместо ссылки на неё. В Python это тоже работает, но часто ли вы сможете встретить такой способ работы со строками? К сожалению, способ почти только теоретический. В целом, тесты показали то, что мы хотели. Делаем выводы самостоятельно. Полный листинг 🌍 #tricks
Пребарај: #archdaily
@arch_shovel · Post #548 · 02.08.2022 г., 19:19
Zeeland. Visualization by WSBY #arch_shovel#archdaily
Hashtags
@arch_shovel · Post #888 · 09.02.2023 г., 15:37
MÆRSK TOWER IN COPENHAGEN. The Mærsk Tower is an extension to the University of Copenhagen’s Faculty of Health and Medical Sciences, located at the intersection of Nørre Allé and Blegdamsvej in Copenhagen. Architecture: Ramsing & Co Photo credit: Adam Mørk #arch_shovel#architecture#archdaily
@arch_shovel · Post #811 · 04.11.2022 г., 14:48
The Immersive Theater and Interactive Museum Project in Kaifeng City, Henan Province, China. Architecture by IND Architects & DA! architects. 2020 #arch_shovel#architecture#archdaily
@arch_shovel · Post #649 · 06.09.2022 г., 07:00
1. Park with observation tower in Spremberg OT Haidemühl 2. Lookout Tower on Devínska Kobyla / Šebo Lichý architects 3. Ateliereen Architecten has proposed a metal and wood configuration for an observation tower in Peize, Netherlands. 4. The Observation Tower Data / Palmett - Markowe Ogrody + RYSY Architekci Rafał Sieraczyński 5. Observation Tower on the River Mur / terrain:loenhart&mayr 6. Viewing Tower Lommel / Ateliereen Architecten 7. THE CROWN, Casalgrande Padana, Italy. Kengo Kuma #architecture#arch_shovel#archdaily
@arch_shovel · Post #634 · 04.09.2022 г., 18:43
VI MALL - work by Av8studio The project is simulated and designed based on a parametric modeling algorithm. Project location: Iceland Software: Revit - 3ds Max - Forest Pack Pro - coronarender – Ps What do you think about this design and visualization? Tag your Architect Friends! #architecture#arch_shovel#archdaily
@arch_shovel · Post #599 · 25.08.2022 г., 03:52
THE GRAND CANAL Experience Center | by Shanghai PTArchitects The project is located in Hanjiang District, Yangzhou, China. The site adjoins the junction of Yunhe North Road and the Grand Canal. The section of the Grand Canal on its south side is a rare east-west water system in the city, with a width of 80 meters. By making use of the 600-meter-long canal landscape belt and the homecoming route with a length of 400 meters, the design team conceived a waterfront living scene within 1 kilometer, which looks like a landscape painting that gradually unfolds at the waterside. The building unfolds towards the Grand Canal, and dialogues with waterscape. The facade features distinct wavy forms at different heights by taking design cues from the rolling waves of the Grand Canal. The wavy structures interweave with glazing, showing the fusion of the real and virtual and closely integrating the building with the site. . 📍Hanjiang District, Yangzhou, CHINA ©️📷 SCHRAN #arch_shovel#architecture#archdaily
@arch_shovel · Post #596 · 20.08.2022 г., 19:22
Casamirador Savassi Apartment Building (2021). Located in Belo Horizonte, Brasil. Designed by Gisele Borgesarq. Photographed by Juberzo and Pablo Gomide. #archdaily#architecture#arch_shovel
@arch_shovel · Post #477 · 03.07.2022 г., 14:25
Stack By Step Red Zone by Ismail Solehudin Architecture. #architecture#arch_shovel#archdaily
@arch_shovel · Post #47 · 03.05.2022 г., 18:22
For Quest. RAW - renaissance of brutalism. Refreshing the urban image with it´s photogenic and bold aesthetic energy, RAW stands for longevity in our aera of constant change. Based upon the mixture between concrete brutalism and post modernism, the monumental ensemble is included in the list of cultural heritage. . Visualization by Beyondvisualarts . #architecture#archdaily#arch_shovel
@arch_shovel · Post #37 · 03.05.2022 г., 11:07
Pictury + SOM | 350 North Morgan 350 North Morgan offers tenants an innovative office space surrounded by Chicago’s best retail, and food and beverage offerings. Located in the desirable Fulton Market neighborhood, 350 North Morgan is a destination for businesses looking to attract the next generation of innovative thinkers. The staggered design and unique façade create a compelling and light, cloud-like exterior, while the shifted volumes create a lofted and expansive interior, highly sought-after in modern office environments. This effect also leads to ample room to design tenant amenities, indoor/outdoor spaces, or terraces. . #arch_shovel#archdaily#architecture
@arch_shovel · Post #916 · 27.02.2023 г., 17:50
Shoreline Crescent's curved façade made from glazed white bricks is fully revealed on site at Folkestone. A playful interpretation of the clinker brick sits within the concave rhythms of the south façade. . #arch_shovel#archdaily#архитектура
@arch_shovel · Post #675 · 18.09.2022 г., 20:09
Completed in 2018, The Fuzhou Strait Culture and Art Center by PES-Architects takes inspiration from the petals of a jasmine blossom, the city flower of Fuzhou. The flower is manifested in the formal language, and the color of the architecture takes inspiration from the petals of a jasmine blossom, the city flower of Fuzhou. “Dividing the large complex into smaller units gives the Centre a more human scale and makes it easy for users to navigate indoors and outdoors. Each building has a core area — a semi-public, curved gallery that follows the curvature of the main façade — that integrates the public interior space with the landscape of the Jasmine Gardens around the building and further with the Mahangzhou island nature reserve in front of the Centre.” Says Pekka Salminen, Founder of PES-Architects. 📸 Photographs: Marc Goodwin, Yong Zhang, Martin Lukasczyk #parametricarchitecture#arch_shovel#archdaily