به نام یگانه برنامه نویس عالم:)
هر نکته ای ک ارزش یاداشت شدن داشته باشه رو مینویسم اینجا... از هرکی... از هرجا:)
به عبارتی هر چی که Navid رو ++ کنه:)
متن باز (open source) هم میکنم شاید به درد کس دیگ هم خورد... :)
@navidnasyry
هر نکته ای ک ارزش یاداشت شدن داشته باشه رو مینویسم اینجا... از هرکی... از هرجا:)
به عبارتی هر چی که Navid رو ++ کنه:)
متن باز (open source) هم میکنم شاید به درد کس دیگ هم خورد... :)
@navidnasyry
🔥5❤2
#soft_skill
#صراحت
"آقا کی گفته باید همه پی وی ها رو خیلی زود جواب بدیم. پیامی ک تو فضای مجازی میاد و میمونه همونقدر ارزش داره که کف اونجا بمونه وگرنه زنگ میزد. حالا زنگم زد کی گفته همون لحظه باید جواب بدم. نتونستم جواب بدم یه ساعت دیگ چند ساعت دیگ زنگ میزنم دیگه چون چه تضمینی داری که بیکار باشم و وقت داشته باشم توی اون لحظه... :))"
این حرف حرفی بود ک یکی از ارشد های شرکت گفت و واقعا حرف دلم بود ک از روی تعارف نمیگفتم به کسی:))
#صراحت
"آقا کی گفته باید همه پی وی ها رو خیلی زود جواب بدیم. پیامی ک تو فضای مجازی میاد و میمونه همونقدر ارزش داره که کف اونجا بمونه وگرنه زنگ میزد. حالا زنگم زد کی گفته همون لحظه باید جواب بدم. نتونستم جواب بدم یه ساعت دیگ چند ساعت دیگ زنگ میزنم دیگه چون چه تضمینی داری که بیکار باشم و وقت داشته باشم توی اون لحظه... :))"
این حرف حرفی بود ک یکی از ارشد های شرکت گفت و واقعا حرف دلم بود ک از روی تعارف نمیگفتم به کسی:))
👍4
#code
#AP
#cpp
#implementation
چند تا نکته یادگرفتیم :)
۱. اول پیاده سازی پترن دیزاین سینگلتون توی cpp. جالب بود ایدش:
لازم به گفتن نیست که سینگلتون همون پترن دیزاینیه که میگه فقط و فقط یکی از اون شی باید توی پروژه ایجاد بشه.
۲. کلید واژه final توی cpp که از CPP 11 به بعد اومده و این اجازه رو نمیده که از کلاس ارث بری بشه. مثل sealed توی سیشارپ احتمالا
۳. #pragma pack(1)
این باعث میشه گپ های حافظه ای که توی تعریف استراکت ایجاد میشه توی cpp رو خالی کنه:)) یعنی حافظه ای که گرفته میشه برا استراکت دقیقا برابر جمع مقدار حافظه اتریبیوت هاش میشه:)) جالبه
#AP
#cpp
#implementation
چند تا نکته یادگرفتیم :)
۱. اول پیاده سازی پترن دیزاین سینگلتون توی cpp. جالب بود ایدش:
لازم به گفتن نیست که سینگلتون همون پترن دیزاینیه که میگه فقط و فقط یکی از اون شی باید توی پروژه ایجاد بشه.
#include <iostream>
using namespace std;
class Singleton {
static Singleton *instance;
int data;
// Private constructor so that no objects can be created.
Singleton() {
data = 0;
}
public:
static Singleton *getInstance() {
if (!instance)
instance = new Singleton;
return instance;
}
int getData() {
return this -> data;
}
void setData(int data) {
this -> data = data;
}
};
//Initialize pointer to zero so that it can be initialized in first call to getInstance
Singleton *Singleton::instance = 0;
int main(){
Singleton *s = s->getInstance();
cout << s->getData() << endl;
s->setData(100);
cout << s->getData() << endl;
return 0;
}
۲. کلید واژه final توی cpp که از CPP 11 به بعد اومده و این اجازه رو نمیده که از کلاس ارث بری بشه. مثل sealed توی سیشارپ احتمالا
۳. #pragma pack(1)
این باعث میشه گپ های حافظه ای که توی تعریف استراکت ایجاد میشه توی cpp رو خالی کنه:)) یعنی حافظه ای که گرفته میشه برا استراکت دقیقا برابر جمع مقدار حافظه اتریبیوت هاش میشه:)) جالبه
🤔1
#HPC
#Linux
#cluster
#ParallelProcessing
#Eucalyptus
Eucalyptus
The open-source cloud refers to software or applications publicly available for the users in the cloud to set up for their own purpose or for their organization.
Eucalyptus is a Linux-based open-source software architecture for cloud computing and also a storage platform that implements Infrastructure a Service (IaaS). It provides quick and efficient computing services. Eucalyptus was designed to provide services compatible with Amazon’s EC2 cloud and Simple Storage Service(S3).
Eucalyptus Architecture
Eucalyptus CLIs can handle Amazon Web Services and their own private instances. Clients have the independence to transfer cases from Eucalyptus to Amazon Elastic Cloud. The virtualization layer oversees the Network, storage, and Computing. Occurrences are isolated by hardware virtualization.
لینک1
لینک 2
#Linux
#cluster
#ParallelProcessing
#Eucalyptus
Eucalyptus
The open-source cloud refers to software or applications publicly available for the users in the cloud to set up for their own purpose or for their organization.
Eucalyptus is a Linux-based open-source software architecture for cloud computing and also a storage platform that implements Infrastructure a Service (IaaS). It provides quick and efficient computing services. Eucalyptus was designed to provide services compatible with Amazon’s EC2 cloud and Simple Storage Service(S3).
Eucalyptus Architecture
Eucalyptus CLIs can handle Amazon Web Services and their own private instances. Clients have the independence to transfer cases from Eucalyptus to Amazon Elastic Cloud. The virtualization layer oversees the Network, storage, and Computing. Occurrences are isolated by hardware virtualization.
لینک1
لینک 2
#انیمیشن
#فیلم
#پاندا_کنگفوکار
یکم کلیشه:)
شدیدا خلاصش میشه اینکه
تغییر کنیم
از تغییر نترسیم:))
تا شرایط رو برای رشد کسی فراهم نکنی، رشد نمیکنه...
نگرانی باعث نمیشه آب زود تر جوش بیاد:))
#فیلم
#پاندا_کنگفوکار
یکم کلیشه:)
تغییر کنیم
از تغییر نترسیم:))
تا شرایط رو برای رشد کسی فراهم نکنی، رشد نمیکنه...
نگرانی باعث نمیشه آب زود تر جوش بیاد:))
❤1
#ParallelProcessing
#University
#Cource
نوید ++ های امروز سر درس پردازش موازی:
MPP : Massively Parallel Processor
is a processing paradigm where hundreds or thousands of processing nodes work on parts of a computational task in parallel. Each of these nodes run individual instances of an operating system...Link
Remote Direct Memory Access:
is a technology that enables two networked computers to exchange data in main memory without relying on the processor, cache or operating system of either computer. Link
so interesting ..:)
MPI : Message Passing Interface
MPL: Message Passing Comunication
SSI: Single System Image
#University
#Cource
نوید ++ های امروز سر درس پردازش موازی:
MPP : Massively Parallel Processor
is a processing paradigm where hundreds or thousands of processing nodes work on parts of a computational task in parallel. Each of these nodes run individual instances of an operating system...Link
Remote Direct Memory Access:
is a technology that enables two networked computers to exchange data in main memory without relying on the processor, cache or operating system of either computer. Link
so interesting ..:)
MPI : Message Passing Interface
MPL: Message Passing Comunication
SSI: Single System Image
TIBCO
What is Massively Parallel Processing? | TIBCO
Massively Parallel Processing (MPP) is a processing paradigm where hundreds or thousands of processing nodes work on parts of a computational task in parallel.
#فیلم
#سینمایی
#خارجی
#mad_max
این فیلمو امروز دیدم:)
منطقا مثل انیمیشن ها، اکثر فیلما آموزنده نیستند و روی نکته خاصی تاکید ندارن ک بشه به راحتی فهمید چی میخواد بگه و میخواد مخاطب چی برداشت کنه ولی خب منطقا ما هم به عنوان مخاطب نباید مثل بز (البته عذر میخوام:) ) صرفا بشینیم فیلمه رو ببینیم و وقتمون رو به فنا بدیم و صرفا سرگرم بشیم:)
پس کلا بیاین سعی کنیم همیشه تا میتونیم فکر کنیم به سکانس و دیالوگ های فیلم های مختلف و گریزی به این بزنیم ک چرا نویسنده این دیالوگ رو نوشته؟ چرا کارگردان چنین صحنه ای ایجاد کرده و... و... و...
و اما بریم سراغ فیلم ک ممکنه اسپویل هم بشه
بخوام تو یه جمله بگم میشه جنگیدن برای بقا، برای زنده موندن، نمردن و کشته نشدن. شاید هرکدوممون تا حالا به دلایل مختلفی جنگیدیم تا بهش برسیم. و احتمالا اون چیزی ک دنبالش بودیم هم سطح جنگندگی ما رو مشخص میکنه. فکر میکنم به نظر نویسنده چیزی مهم تر از جون آدم نیست ک براش بجنگه و کل فیلم داره به روش های مختلفی اینو به نمایش میذاره:)
جالب اونجاس ک تنگنا ها و سختی و زجر باعث میشه ادم بیشتر به تکاپو بیوفته و دست و پا بزنه تا بتونه خلاص بشه از اوو سختی و به یه استیت با سختی یکم راحت تر بره:) تازه استیتی ک اصلا استیبل نیست و هر لحظه ممکنه باز بره به یه استیت سخت تر از سختی های قبلی:)))
فکر کنم خیلی سخت شد:)
ولی خب چرا من وقتی یه سختی میگذرونم معمولا انتظار دارم دیگ نبینم چنین سختی ای رو... درحالی ک به احتمال زیاد بد تر از اونا رو خواهم دید؟ چرا؟
اصلا چه چیزایی ارزش جنگیدن رو داره؟ ارزش چقدر جنگیدن داره؟ چطور جنگیدن و...؟
اگر فیلمو دیده باشین شاید بگین این چرت و پرتا چیه میگم:) ولی هری باید برداشت خودشو بکنه دیگه و بارشو ببینده:) حتی اگه نویسنده اصلا منظورش چنین چیزی نبوده:)
#سینمایی
#خارجی
#mad_max
این فیلمو امروز دیدم:)
منطقا مثل انیمیشن ها، اکثر فیلما آموزنده نیستند و روی نکته خاصی تاکید ندارن ک بشه به راحتی فهمید چی میخواد بگه و میخواد مخاطب چی برداشت کنه ولی خب منطقا ما هم به عنوان مخاطب نباید مثل بز (البته عذر میخوام:) ) صرفا بشینیم فیلمه رو ببینیم و وقتمون رو به فنا بدیم و صرفا سرگرم بشیم:)
پس کلا بیاین سعی کنیم همیشه تا میتونیم فکر کنیم به سکانس و دیالوگ های فیلم های مختلف و گریزی به این بزنیم ک چرا نویسنده این دیالوگ رو نوشته؟ چرا کارگردان چنین صحنه ای ایجاد کرده و... و... و...
و اما بریم سراغ فیلم ک ممکنه اسپویل هم بشه
بخوام تو یه جمله بگم میشه جنگیدن برای بقا، برای زنده موندن، نمردن و کشته نشدن. شاید هرکدوممون تا حالا به دلایل مختلفی جنگیدیم تا بهش برسیم. و احتمالا اون چیزی ک دنبالش بودیم هم سطح جنگندگی ما رو مشخص میکنه. فکر میکنم به نظر نویسنده چیزی مهم تر از جون آدم نیست ک براش بجنگه و کل فیلم داره به روش های مختلفی اینو به نمایش میذاره:)
جالب اونجاس ک تنگنا ها و سختی و زجر باعث میشه ادم بیشتر به تکاپو بیوفته و دست و پا بزنه تا بتونه خلاص بشه از اوو سختی و به یه استیت با سختی یکم راحت تر بره:) تازه استیتی ک اصلا استیبل نیست و هر لحظه ممکنه باز بره به یه استیت سخت تر از سختی های قبلی:)))
فکر کنم خیلی سخت شد:)
ولی خب چرا من وقتی یه سختی میگذرونم معمولا انتظار دارم دیگ نبینم چنین سختی ای رو... درحالی ک به احتمال زیاد بد تر از اونا رو خواهم دید؟ چرا؟
اصلا چه چیزایی ارزش جنگیدن رو داره؟ ارزش چقدر جنگیدن داره؟ چطور جنگیدن و...؟
اگر فیلمو دیده باشین شاید بگین این چرت و پرتا چیه میگم:) ولی هری باید برداشت خودشو بکنه دیگه و بارشو ببینده:) حتی اگه نویسنده اصلا منظورش چنین چیزی نبوده:)
🤔1
البته اینم بود برا امروز
https://news.1rj.ru/str/coaching_ce/73
https://news.1rj.ru/str/coaching_ce/73
Telegram
مشورت کامپیوتریها
#مشورت_4
«دیتابیس و کاربردهای آن_قسمت اول»
((در این مشورت قراره راجع به چالشهای دیتابیس و پیچیدگی پیاده سازی اون در پیام رسانهایی مثل تلگرام صحبت کنیم.))
🟡بخشهای این مشورت:
🔹فرهنگ اوپن سورس
01:00
🔹کاربرد درس دیتابیس و اپلکیشنهایی که نیازمند دیتابیس…
«دیتابیس و کاربردهای آن_قسمت اول»
((در این مشورت قراره راجع به چالشهای دیتابیس و پیچیدگی پیاده سازی اون در پیام رسانهایی مثل تلگرام صحبت کنیم.))
🟡بخشهای این مشورت:
🔹فرهنگ اوپن سورس
01:00
🔹کاربرد درس دیتابیس و اپلکیشنهایی که نیازمند دیتابیس…
👍1
#filesystem_encryption
#general
Filesystem-level encryption, often called file-based encryption, FBE, or file/folder encryption, is a form of disk encryption where individual files or directories are encrypted by the file system itself. link
#linux
LUKS implements a platform-independent standard on-disk format for use in various tools. This facilitates compatibility and interoperability among different programs and operating systems, and assures that they all implement password management in a secure and documented manner. Link
#windows
The Encrypting File System (EFS) on Microsoft Windows is a feature introduced in version 3.0 of NTFS[1] that provides filesystem-level encryption. The technology enables files to be transparently encrypted to protect confidential data from attackers with physical access to the computer. Link
#general
Filesystem-level encryption, often called file-based encryption, FBE, or file/folder encryption, is a form of disk encryption where individual files or directories are encrypted by the file system itself. link
#linux
LUKS implements a platform-independent standard on-disk format for use in various tools. This facilitates compatibility and interoperability among different programs and operating systems, and assures that they all implement password management in a secure and documented manner. Link
#windows
The Encrypting File System (EFS) on Microsoft Windows is a feature introduced in version 3.0 of NTFS[1] that provides filesystem-level encryption. The technology enables files to be transparently encrypted to protect confidential data from attackers with physical access to the computer. Link
Wikipedia
Filesystem-level encryption
form of disk encryption where individual files or directories are encrypted by the file system itself
#watsonx
#IBM
یکی از محصولهای IBM که عملا داره ai as service میده:)))
Watsonx is IBM's commercial generative AI and scientific data platform based on cloud. It offers a studio, data store, and governance toolkit. It supports multiple large language models (LLMs) including IBM Granite
The platform is described as an AI tool tailed to companies and a one which can be customized for customers' needs and trained on their confidential data, as client data is said to be not collected by IBM for further training of their models. It is also capable of fine-tuning, an approach which makes training pre-trained models on the newly introduced data possible. Link
#IBM
یکی از محصولهای IBM که عملا داره ai as service میده:)))
Watsonx is IBM's commercial generative AI and scientific data platform based on cloud. It offers a studio, data store, and governance toolkit. It supports multiple large language models (LLMs) including IBM Granite
The platform is described as an AI tool tailed to companies and a one which can be customized for customers' needs and trained on their confidential data, as client data is said to be not collected by IBM for further training of their models. It is also capable of fine-tuning, an approach which makes training pre-trained models on the newly introduced data possible. Link
#proxmox
امروز پروکماکس رو با موفقیت نصب و راه اندازی کردیم برا درس cloud computing که ماشین بدیم به بچه ها ایشالله:)))
چالش های جالبی داشت در کل که یه سامری بگم اینجا از هرکدوم:
اول اینکه کلا ایپی درست حسابی نداشتیم. جالبیش این بود ایپی ای که گرفته بود لینوکس پروکسماکس (وقتی پروکماکس رو نصب میکنیم باهاش یه لینوکس هم نصب میکنه چون همونطور که میدونین پروکماکس یه hypervisor نوع ۱ هست و عملا همون سیستم عامل رو هایپروایزر میکنه) روی اینترفیس مربوط به خود Lan نبود و مربوط به شبکه vm ش بود. اونو دادیم از dhcp بگیره
بعد برا اضافه کردن یه هارد دیسک ۱ ترابایتی هم اول اونو با پارتیشنینگ LVM ایجاد کردیم و دادیم بهش
بعدم vm ساختیم و کلون گرفتیم و الی آخر...:))
این کورس هم باید ببینم و دیدم یکم:))
لینک
امروز پروکماکس رو با موفقیت نصب و راه اندازی کردیم برا درس cloud computing که ماشین بدیم به بچه ها ایشالله:)))
چالش های جالبی داشت در کل که یه سامری بگم اینجا از هرکدوم:
اول اینکه کلا ایپی درست حسابی نداشتیم. جالبیش این بود ایپی ای که گرفته بود لینوکس پروکسماکس (وقتی پروکماکس رو نصب میکنیم باهاش یه لینوکس هم نصب میکنه چون همونطور که میدونین پروکماکس یه hypervisor نوع ۱ هست و عملا همون سیستم عامل رو هایپروایزر میکنه) روی اینترفیس مربوط به خود Lan نبود و مربوط به شبکه vm ش بود. اونو دادیم از dhcp بگیره
بعد برا اضافه کردن یه هارد دیسک ۱ ترابایتی هم اول اونو با پارتیشنینگ LVM ایجاد کردیم و دادیم بهش
بعدم vm ساختیم و کلون گرفتیم و الی آخر...:))
این کورس هم باید ببینم و دیدم یکم:))
لینک
YouTube
Let's Install Proxmox 8.0!
Visit https://Linode.com/CraftComputing to start your $100, 60-Day Trial, and move your services to your own personal cloud today!
It's been a while since I've updated my tutorial videos, so today, let's install Proxmox 8.0! This is a beginner's guide to…
It's been a while since I've updated my tutorial videos, so today, let's install Proxmox 8.0! This is a beginner's guide to…
#string_interning
#dotnet
#C#
Interned strings have the following characteristics:
Two interned strings that are identical will have the same address in memory.
Memory occupied by interned strings is not freed until your application terminates.
Interning a string involves calculating a hash and looking it up in a dictionary which consumes CPU cycles.
If multiple threads intern strings at the same time they will block each other because accesses to the dictionary of interned strings are serialized.
The consequences of these characteristics are:
You can test two interned strings for equality by just comparing the address pointer which is a lot faster than comparing each character in the string. This is especially true if the strings are very long and start with the same characters. You can compare interned strings with the Object.ReferenceEquals method, but it is safer to use the string == operator because it checks to see if the strings are interned first.
If you use the same string many times in your application, your application will only store one copy of the string in memory reducing the memory required to run your application.
If you intern many different strings this will allocate memory for those strings that will never be freed, and your application will consume ever increasing amounts of memory.
If you have a very large number of interned strings, string interning can become slow, and threads will block each other when accessing the interned string dictionary.
You should use string interning only if:
The set of strings you are interning is fairly small.
You compare these strings many times for each time that you intern them.
You really care about minute performance optimizations.
You don't have many threads aggressively interning strings.
#dotnet
#C#
Interned strings have the following characteristics:
Two interned strings that are identical will have the same address in memory.
Memory occupied by interned strings is not freed until your application terminates.
Interning a string involves calculating a hash and looking it up in a dictionary which consumes CPU cycles.
If multiple threads intern strings at the same time they will block each other because accesses to the dictionary of interned strings are serialized.
The consequences of these characteristics are:
You can test two interned strings for equality by just comparing the address pointer which is a lot faster than comparing each character in the string. This is especially true if the strings are very long and start with the same characters. You can compare interned strings with the Object.ReferenceEquals method, but it is safer to use the string == operator because it checks to see if the strings are interned first.
If you use the same string many times in your application, your application will only store one copy of the string in memory reducing the memory required to run your application.
If you intern many different strings this will allocate memory for those strings that will never be freed, and your application will consume ever increasing amounts of memory.
If you have a very large number of interned strings, string interning can become slow, and threads will block each other when accessing the interned string dictionary.
You should use string interning only if:
The set of strings you are interning is fairly small.
You compare these strings many times for each time that you intern them.
You really care about minute performance optimizations.
You don't have many threads aggressively interning strings.
#web
#server_side
#client_side
In summary, client-side routing is a technique for handling web application navigation and page rendering in the browser using JavaScript frameworks, while server-side routing is a technique for handling navigation and rendering on the server using server-side technologies.
Client-side and server-side routing are two different approaches to handling web application navigation and page rendering:
Client-side routing is a technique where the browser renders the pages and handles navigation without requiring a full page refresh. This is achieved using JavaScript frameworks like React, Angular, or Vue.js. In client-side routing, the browser makes AJAX requests to the server to fetch data, and then the JavaScript framework dynamically updates the content on the page. This approach provides a seamless user experience, as it avoids the delay and flicker associated with full page reloads.
Server-side routing, on the other hand, is a technique where the server is responsible for rendering the pages and handling navigation. This is achieved using server-side technologies like PHP, Ruby on Rails, or Django. In server-side routing, the server generates HTML pages and sends them to the browser for rendering. This approach is more suitable for applications that require strong SEO (Search Engine Optimization) or that need to support older browsers that may not have full support for client-side JavaScript.
#server_side
#client_side
In summary, client-side routing is a technique for handling web application navigation and page rendering in the browser using JavaScript frameworks, while server-side routing is a technique for handling navigation and rendering on the server using server-side technologies.
Client-side and server-side routing are two different approaches to handling web application navigation and page rendering:
Client-side routing is a technique where the browser renders the pages and handles navigation without requiring a full page refresh. This is achieved using JavaScript frameworks like React, Angular, or Vue.js. In client-side routing, the browser makes AJAX requests to the server to fetch data, and then the JavaScript framework dynamically updates the content on the page. This approach provides a seamless user experience, as it avoids the delay and flicker associated with full page reloads.
Server-side routing, on the other hand, is a technique where the server is responsible for rendering the pages and handling navigation. This is achieved using server-side technologies like PHP, Ruby on Rails, or Django. In server-side routing, the server generates HTML pages and sends them to the browser for rendering. This approach is more suitable for applications that require strong SEO (Search Engine Optimization) or that need to support older browsers that may not have full support for client-side JavaScript.