facebook 直播_什么时候是在Facebook Live上直播的最佳时间? 我分析了5,000个Facebook帖子以找出答案。...
facebook 直播
by Ofir Chakon
由Ofir Chakon
什么时候是在Facebook Live上直播的最佳时间? 我分析了5,000个Facebook帖子以找出答案。 (When is the best time to stream on Facebook Live? I analyzed 5,000 Facebook posts to find out.)
Streaming on Facebook Live can be a powerful marketing strategy for startups and businesses. They can share knowledge, provide value, get exposure and collect high-quality leads.
对于初创企业和企业而言,在Facebook Live上流式传输可能是一种强大的营销策略。 他们可以分享知识,提供价值,获得曝光并收集高质量的线索。
Prepare your Facebook Live session upfront. Researching about your target audience and build a detailed agenda. The session can boost your business dramatically.
预先准备您的Facebook Live会话。 研究您的目标受众并制定详细的议程。 会议可以极大地促进您的业务。
I was Chief of Product and Technology of my previous startup dealing with fraud detection. I decided to try Facebook Live as a new marketing strategy.
我曾在以前的初创公司中负责欺诈检测的产品和技术总监。 我决定尝试将Facebook Live作为一种新的营销策略。
It was still fairly new at the time. Once a Facebook Live session was up, relevant people got Facebook notifications to join the session. This increased the exposure even more.
当时还很新。 Facebook Live会话启动后,相关人员会收到Facebook通知以加入会话。 这进一步增加了曝光。
There are many posts talking about how to better build your Facebook live session. They discuss which topics to cover, building an agenda, camera angles, session duration, and more.
有许多文章讨论如何更好地构建您的Facebook实时会话。 他们讨论了要涵盖的主题,制定议程,摄像机角度,会话持续时间等。
But there is one piece of the puzzle that business owners and marketers often tend to forget or do not pay attention to: When is the best time to stream your Facebook Live session?
但是,企业所有者和市场营销人员往往会忘记或不注意一个难题: 何时才是播放Facebook Live会话的最佳时间?
You can answer this question using an educated guess based on your familiarity with the target audience.
您可以根据对目标受众的熟悉程度,使用有根据的猜测来回答此问题。
For example:
例如:
- Pregnant moms are ready to consume your Live session on Monday afternoon.怀孕的妈妈们准备好在周一下午参加您的现场直播。
- Teenagers at the ages of 18–22 are in the right mindset on Saturday morning.周六早上,年龄在18-22岁之间的青少年心态正确。
But there is so much data around us that we can use with a few clicks of a button. You actually stay behind if you don’t make a proper usage of some of the data available.
但是我们周围有太多数据,只需单击几下就可以使用。 如果您未正确使用某些可用数据,则实际上您会落后。
Almost every marketing platform or social network opens API services. You, as a technological entrepreneur, can easily consume these. This data can provide valuable conclusions that can drive your business objectives beyond your competitors.
几乎每个营销平台或社交网络都开放API服务。 作为技术企业家,您可以轻松地消费这些。 这些数据可以提供有价值的结论,可以使您的业务目标超越竞争对手。
This approach is often called Data-driven decisions.
这种方法通常称为数据驱动决策 。
Once you start justifying any or at least most of your business decisions using data you own or data you can collect from different resources, you can stop guessing and start making data-driven decisions.
一旦开始使用自己拥有的数据或可以从不同资源收集的数据来证明任何或至少大部分业务决策的合理性,就可以停止猜测并开始制定由数据驱动的决策。
I like to think of data-driven decisions as crowd-sourcing. Lior Zoref was on this TED talk . He invited an ox to the stage and asked the audience to guess its’ weight. If you watched this, you were probably overwhelmed by how accurate the crowd’s average was compared to the real weight of the ox: 1,792 pounds or 1795 pounds!
我喜欢将数据驱动的决策视为众包。 Lior Zoref正在TED演讲中 。 他邀请了一只牛到舞台上,并要求观众猜测其重量。 如果您观看了此内容,那么您可能会不知所措,将人群的平均水平与牛的真实体重进行比较的准确性如何:1,792磅或1795磅!
When you’re making guesses about your business objectives as individuals, you’re not different than any individual sitting in the crowd and trying to evaluate the ox’s weight. You can even be the one who guessed 300 pounds or 8000 pounds, which may cost your business a lot of unnecessary expenses.
当您对个人的业务目标进行猜测时,您与坐在人群中并试图评估公牛体重的个人没有什么不同。 您甚至可以成为猜到300磅或8000磅的人,这可能使您的企业损失很多不必要的费用。
But, if you’re using the wisdom of the crowd to make data-driven decisions, you’ll most likely be ahead of every other individual. In business terms, you’ll be ahead of your competitors.
但是,如果您要利用人群的智慧做出由数据决定的决策,那么您很可能会领先于其他所有人。 从业务角度来讲,您将领先于竞争对手。
I’m not a pure marketer. But with basic data analysis skills I can push my business forward in all aspects, including marketing.
我不是一个纯粹的商人。 但是,凭借基本的数据分析技能,我可以在包括营销在内的各个方面推动业务发展。
I’m going to walk you through a practical step-by-step guide about how to access Facebook data. Then how to analyze it based on our needs about the optimized time to broadcast on Facebook Live.
我将向您介绍有关如何访问Facebook数据的实用分步指南。 然后如何根据我们有关在Facebook Live上播放的最佳时间的需求进行分析。
To follow this guide you need:
要遵循本指南,您需要:
- A Facebook account一个Facebook帐户
A Facebook group you would like to analyze
您想分析的Facebook群组
If it’s a private group then you need to be a group member
如果是私人群组,则您需要成为群组成员
- Python 2.7 installed安装了Python 2.7
- Jupyter notebook installed安装了Jupyter笔记本
Facebook graph API Python library installed
安装了Facebook graph API Python库
A Jupyter notebook is a recommended tool for data analysis in Python. It has a lot of highlights. It enables you to run snippets of code and save the results in memory. So you won’t run all your scripts over and over again every time you implement a minor change. This is crucial when doing data analysis because some tasks can take a lot of execution time.
建议使用Jupyter笔记本进行Python数据分析。 它有很多亮点。 它使您可以运行代码片段并将结果保存在内存中。 因此,您不会在每次实施微小更改时一遍又一遍地运行所有脚本。 这在执行数据分析时至关重要,因为某些任务可能会花费大量执行时间。
Although it’s not essential, I recommend working inside a Python virtual environment. Here is a post I wrote about the advantages of a virtual environment when using Python.
尽管不是必需的,但我建议在Python虚拟环境中工作。 这是我写的关于使用Python时虚拟环境的优势的文章。
I recommend working in an Ubuntu environment when doing data-analysis using Jupyter notebooks.
使用Jupyter笔记本进行数据分析时,建议在Ubuntu环境中工作。
第1步-获取Facebook组ID (Step 1 — Getting the Facebook group ID)
To get data from Facebook API, we need to specify the ID of the entity we want to get data from, in our case, a Facebook group.
要从Facebook API获取数据,我们需要指定要从Facebook组获取数据的实体的ID。
Lookup-id.com is a nice tool you can use to find the ID of a group based on its URL. Copy the URL of your group and paste it in the search bar.
Lookup-id.com是一个不错的工具,可用于根据其URL查找组的ID。 复制您论坛的网址,然后将其粘贴到搜索栏中。
In this article, we will use the group: Web Design and Development.
在本文中,我们将使用以下组: Web设计和开发 。
ID: 319479604815804
ID(标识号): 319479604815804
第2步-了解Graph API Explorer (Step 2 — Getting to know the Graph API Explorer)
To get the most out of Facebook API besides documentation, Facebook has developed a playground for developers called the Graph API Explorer.
为了最大程度地利用除文档之外的Facebook API,Facebook为开发人员开发了一个称为Graph API Explorer的游乐场。
The Graph API Explorer enables us to get a temporary access token and start examining the capabilities that Facebook API has to offer.
Graph API Explorer使我们能够获取临时访问令牌,并开始检查Facebook API必须提供的功能。
Click on Get Token. Don’t select any permission. Click Get Access Token .
单击获取令牌。 不要选择任何权限。 单击获取访问令牌 。
Facebook API has many endpoints you can use. In this guide, we are going to use two main endpoints:
Facebook API有许多可以使用的终结点。 在本指南中,我们将使用两个主要端点:
The group endpoint
组端点
The reactions endpoint
React终点
To figure out the structure of the response you’re expecting to get, specify the endpoint URL and click Submit.
要弄清楚您期望得到的响应的结构,请指定端点URL并单击Submit 。
Let’s examine the URL endpoint for grabbing the last posts from the group’s feed. Type this URL in the Graph API Explorer:
让我们检查一下URL终结点,以获取论坛供稿中的最新帖子。 在Graph API Explorer中输入以下URL:
319479604815804/feed
and hit Submit.
然后点击Submit 。
You should now see the last posts from the group’s feed in a JSON structure. It contains the post’s content, its id and the updated time. By clicking on one of the id’s and adding to the end of the URL:
现在,您应该以JSON结构查看论坛供稿中的最新帖子。 它包含帖子的内容,其ID和更新时间。 通过单击其中一个ID并将其添加到URL的末尾:
319479604815804_1468216989942054/reactions?summary=total_count
You should see a list of the reactions for the specific post, and a summary of the total count of reactions.
您应该看到特定帖子的React列表,以及React总数的摘要。
This way you can play around with all the features the Facebook API has to offer.
这样,您就可以使用Facebook API必须提供的所有功能。
Another tool for examining API endpoints of APIs which don’t offer a playground is Postman. You can read more about this tool and essential tools for web developers.
邮递员(Postman)是另一个用于检查不提供游乐场的API的API端点的工具。 您可以阅读有关此工具和面向Web开发人员的基本工具的更多信息。
步骤3 —我们的计划和假设 (Step 3 — Our plan and assumptions)
Our goal is to find the best time to have a Facebook Live session in the group that contains our target audience. To do that, we assume that the more activity there is in the group at a specific time, the most likely our Facebook Live session will gain more traction.
我们的目标是找到在包含目标受众的小组中进行Facebook Live会议的最佳时间。 为此,我们假设在特定时间组中的活动越多,我们的Facebook Live会话最有可能获得更多关注。
So our goal now is to figure out when there is a peak in the group’s activity over time. And by when I mean a specific weekday and time.
因此,我们现在的目标是找出小组活动随时间推移达到峰值的时间。 当我指的是特定的工作日和时间时。
To do that, we are going to grab the last 5,000 posts from the group’s feed. Then we’ll plot the distribution of the times they were updated.
为此,我们将从该小组的Feed中获取最后5,000个帖子。 然后,我们将绘制更新时间的分布图。
We assume that longer posts indicate more activity in the group because members spend more time in the group writing them. So, our next step will be to take into consideration the length of each post in the distribution.
我们假设较长的帖子表明该小组中有更多活动,因为成员在该小组中花费了更多时间来撰写帖子。 因此,我们的下一步将是考虑分发中每个帖子的长度。
Reaction on Facebook is probably a great indication of people engaging with a specific post. Thus, our last step will be to collect the total number of reactions
for each post. Then take that into account in the distribution of activity over weekdays and hours.
在Facebook上的React可能是人们参与特定帖子的一个好兆头。 因此,我们的最后一步将是收集每个帖子的reactions
总数。 然后在工作日和小时的活动分布中考虑到这一点。
Because reactions
may come after the post, we should be cautious using this data analysis approach.
由于帖子发布后可能会发生reactions
,因此使用此数据分析方法时应谨慎。
步骤4 —让我们分析一些数据! (Step 4 — Let’s analyze some data!)
To start a Jupyter notebook, you should execute:
要启动Jupyter笔记本,您应该执行:
ipython notebook
and then choose New → Python 2.
然后选择新建→Python 2。
To analyze and plot the data, we are going to use the numpy
and matplotlib
libraries. These are very popular Python libraries you should use to better analyze your data.
为了分析和绘制数据,我们将使用numpy
和matplotlib
库。 这些是非常流行的Python库,您应该使用它来更好地分析数据。
Let’s import all the libraries we need:
让我们导入所需的所有库:
import matplotlib.pyplot as pltimport numpy as npimport facebookimport urlparseimport datetimeimport requests
and specify our access token and group id:
并指定我们的访问令牌和组ID:
ACCESS_TOKEN = 'INSERT_ACCESS_TOKEN_HERE'GROUP_ID = '319479604815804' # Web Design and Development group
Then, let’s initialize the API object with our access token:
然后,让我们使用访问令牌初始化API对象:
graph = facebook.GraphAPI(ACCESS_TOKEN)
Now we want to grab the posts from the group’s feed. To avoid errors during the API calls, we will limit each API call to 50 posts and iterate over 100 API calls:
现在我们要从论坛的提要中获取帖子。 为了避免在API调用期间出错,我们将每个API调用限制为50个帖子,并迭代100个以上的API调用:
posts = []url = "{}/feed?limit=50".format(GROUP_ID)until = Nonefor i in xrange(100): if until is not None: url += "&until={}".format(until) response = graph.request(url) data = response.get('data') if not data: break posts = posts + data next_url = response.get("paging").get("next") parsed_url = urlparse.urlparse(next_url) until = urlparse.parse_qs(parsed_url.query)["until"][0]
In each API call, we specify the until parameter to get older posts.
Now, let’s organize the posts into weekdays and hours of the day:
weekdays = {i: 0 for i in xrange(7)}
hours_of_day = {i: 0 for i in xrange(24)}
hours_of_week = np.zeros((7,24), dtype=np.int)for post in posts: updated = datetime.datetime.strptime(post.get("updated_time"), "%Y-%m-%dT%H:%M:%S+0000") weekday = updated.weekday() hour_of_day = updated.hour weekdays[weekday] += 1 hours_of_day[hour_of_day] += 1 hours_of_week[weekday][hour_of_day] += 1
and then, plot the results using matplotlib
bar charts:
然后,使用matplotlib
条形图绘制结果:
plt.bar(weekdays.keys(), weekdays.values(), color='g')plt.show()
plt.bar(hours_of_day.keys(), hours_of_day.values(), color='r')plt.show()
With only this basic analysis, we can already learn a lot about better or worse time slots for broadcasting to this group. But it does not seem informative enough. Maybe because the data is divided into 2 graphs and missing some critical information.
仅通过这种基本分析,我们就可以学到更多或更好的时隙广播给该组。 但这似乎还不足以提供信息。 可能是因为数据被分为2个图,并且缺少一些关键信息。
Let’s try to present a heat map of the data, that enables us to see 3D information:
让我们尝试呈现数据的热图,使我们能够查看3D信息:
plt.imshow(hours_of_week, cmap='hot')plt.show()
Well, this is much better! We can see that the group is very active on Monday to Friday between 6:00 am and 10:00 am.
好吧,这好多了! 我们可以看到,该小组在星期一至星期五的6:00 am至10:00 am之间非常活跃。
Now let’s take into consideration to post length and see how it affects the results:
现在,让我们考虑发布时长,看看它如何影响结果:
weekdays_content = {i: 0 for i in xrange(7)}hours_of_day_content = {i: 0 for i in xrange(24)}hours_of_week_content = np.zeros((7,24), dtype=np.int)for post in posts: updated = datetime.datetime.strptime(post.get("updated_time"), "%Y-%m-%dT%H:%M:%S+0000") weekday = updated.weekday() hour_of_day = updated.hour content_length = len(post["message"]) if "message" in post else 1 weekdays_content[weekday] += content_length hours_of_day_content[hour_of_day] += content_length hours_of_week_content[weekday][hour_of_day] += content_length
The heatmap we get:
我们获得的热图:
This is nice but should be treated with caution. On one hand, we can see a very specific time that is the optimized time slot to have our Facebook Live session. But, it might be an outlier of a super long post.
很好,但应谨慎对待。 一方面,我们可以看到一个非常特定的时间,这是进行我们的Facebook Live会话的最佳时间段。 但是,这可能是超长职位的离群值。
I’ll leave it to you to figure it out in your next data analysis project. Take a larger amount of posts or grab an older batch of 5000 posts from the group’s feed.
我将留给您在下一个数据分析项目中加以解决。 从该小组的供稿中获取更多信息或获取旧的5000条信息。
To take reactions
into account when analyzing the data, we need to make another API call for each post.
为了在分析数据时考虑到reactions
,我们需要为每个帖子进行另一个API调用。
This is because it’s a different API endpoint:
这是因为它是不同的API端点:
weekdays_reactions = {i: 0 for i in xrange(7)}hours_of_day_reactions = {i: 0 for i in xrange(24)}hours_of_week_reactions = np.zeros((7,24), dtype=np.int)for i, post in enumerate(posts): url = "https://graph.facebook.com/v2.10/{id}/reactions?access_token={token}&summary=total_count".format( id=post["id"], token=ACCESS_TOKEN )
headers = { "Host": "graph.facebook.com" }
response = requests.get(url, headers=headers)
try: total_reactions = 1 + response.json().get("summary").get("total_count") except: total_reactions = 1
updated = datetime.datetime.strptime(post.get("updated_time"), "%Y-%m-%dT%H:%M:%S+0000") weekday = updated.weekday() hour_of_day = updated.hour weekdays_reactions[weekday] += total_reactions hours_of_day_reactions[hour_of_day] += total_reactions hours_of_week_reactions[weekday][hour_of_day] += total_reactions
We used a low-level approach by specifying the exact HTTP request and did not use the Facebook Python library. This is because that library doesn’t support the last version of the Facebook API required when querying the reactions
endpoint.
我们通过指定确切的HTTP请求来使用低级方法,而未使用Facebook Python库。 这是因为该库不支持查询reactions
端点时所需的Facebook API的最新版本。
The heat map generated from this data:
根据此数据生成的热图:
We can conclude that the three approaches we used agree on Monday and Wednesday, 6:00 am to 7:00 am.
我们可以得出结论,我们使用的三种方法在星期一和星期三上午6:00到上午7:00达成一致。
结论 (Conclusions)
Data analysis can be challenging and often requires creativity. But it also exciting and very rewarding.
数据分析可能具有挑战性,通常需要创造力。 但这也令人兴奋并且非常有意义。
After choosing our time to broadcast on Facebook Live based on the analysis presented here, we had a huge success and a lot of traction during our Live session.
根据此处介绍的分析选择了在Facebook Live上进行直播的时间后,我们在Live环节中取得了巨大的成功并获得了很多关注。
I encourage you to try and use data analysis to make data-driven decisions in your next business move. And start thinking in terms of data-driven decisions.
我鼓励您尝试使用数据分析在下一步业务中做出以数据为依据的决策。 并开始根据数据驱动的决策进行思考。
You can find the Github repository here.
您可以在此处找到Github存储库。
I originally published this on CodingStartups.
我最初将此内容发布在CodingStartups上 。
翻译自: https://www.freecodecamp.org/news/the-best-time-to-stream-on-facebook-live-my-analysis-5-000-facebook-posts-c8346b732d0f/
facebook 直播
相关文章:

解决keepalived脑裂问题
检测思路:正常情况下keepalived的VIP地址是在主节点上的,如果在从节点发现了VIP,就设置报警信息 脚本如下: #!/bin/bash # 检查脑裂的脚本,在备节点上进行部署 LB01_VIP10.10.10.229 LB01_IP10.10.10.129 LB02_IP10.10…

iOS 根据中文字符串排序出字母索引
// 传入字符串数组 返回索引字典 - (NSDictionary *)createCharacter:(NSMutableArray *)strArr {NSMutableDictionary *dict [NSMutableDictionary dictionary];for (NSString *stringdict in strArr) {NSString *string stringdict;if ([string length]) {NSMutableString …

devops开发运维训练营_嗨,网络开发人员训练营的毕业生:这是您第一份工作需要了解的内容。...
devops开发运维训练营by Rachel Bird雷切尔伯德(Rachel Bird) 嗨,网络开发人员训练营的毕业生:这是您第一份工作需要了解的内容。 (Hey web dev bootcamp grads: Here’s what you need to know for your first job.) You worked your butt off and gai…

[bzoj1042][HAOI2008]硬币购物
有三种硬币,每种有自己的币值。 然后有n次询问,每次都给出每种硬币的数量和要付的钱s,求有多少种付法。n<1000 s<100000 ------ 不考虑限制,就是个简单dp.... 有限制的时候,我们可以考虑反过来用总的方案数量剪掉…

Windows netstat 查看端口、进程占用
目标:在Windows环境下,用netstat命令查看某个端口号是否占用,为哪个进程所占用. 操作:操作分为两步:(1)查看该端口被那个PID所占用;方法一:有针对性的查看端口,使用命令 …

iOS Named colors do not work prior to iOS 11.0问题解决
原文链接 https://stackoverflow.com/questions/48014246/named-colors-do-not-work-prior-to-ios-11-0-error-referring-to-a-storyboard/52967313#52967313 1 打开对应文件source code 2 粘贴查找 使用正则表达式 color key(.*) name.* 3 用以下代码覆盖 color key$1 …

如何在StackOverflow上获得第一个标签徽章-以及为什么它很重要。
by Angelos Chalaris通过安吉洛斯查拉利斯(Angelos Chalaris) 如何在StackOverflow上获得第一个标签徽章-以及为什么它很重要。 (How to get your first tag badge on StackOverflow — and why it’s important.) Every developer uses StackOverflow in different ways. Som…

int数据类型
1 a 18862 # 取商和余数3 print(a.__divmod__(10)) 4 5 # r反转,想当于 10-18866 print(a.__rsub__(10)) 7 8 # 取绝对值9 print(a.__abs__(), abs(a)) 10 11 #商取整 12 print(a.__floordiv__(10), a // 10) 转载于:https://www.cnblogs.com/xh4528/p/6497629.html

使用Google 官方的控件SwipeRefreshLayout实现下拉刷新功能
之前做东西的时候,经常会用到下拉刷新的功能,之前大家都在使用Github上的一个很著名的开源项目 PullToRefresh 但是,现在好消息来了,google在19.1版本的support-v4兼容包下面正式提供了官方的下拉刷新组件——SwipeRefreshLayout…

iOS 没到年底NSDate 时间出错问题
NSDate *currentDate [NSDate date];//获取当前时间,日期 NSDateFormatter *dateFormatter [[NSDateFormatter alloc] init]; [dateFormatter setDateFormat:"yyyy-MM-dd HH:mm:ss"]; // [dateFormatter setDateFormat:"YYYY-MM…

react 统一字段验证_如何使用React的受控输入进行即时表单字段验证
react 统一字段验证by Gosha Arinich通过Gosha Arinich 如何使用React的受控输入进行即时表单字段验证 (How to use React’s controlled inputs for instant form field validation) Controlled inputs enable simple things, like disabling the Submit button when some fi…

UISearchBar和 UISearchDisplayController的使用
感觉好多文章不是很全面,所以本文收集整合了网上的几篇文章,感觉有互相补充的效果。 如果想下载源码来看:http://code4app.com/search/searchbar 。本源码与本文无关 1、searchBar 本例子实现布局:上面是一个navigationController…

iOS 获取指定时间的前后N个月
https://www.cnblogs.com/SUPER-F/p/7298548.html 正数为后 负数为前 -(NSDate *)getPriousorLaterDateFromDate:(NSDate *)date withMonth:(NSInteger)month { NSDateComponents *comps [[NSDateComponents alloc] init]; [comps setMonth:month]; NSCalendar *calender …

JS高级程序设计第五章读书笔记
1.引用类型的值(对象)是引用类型的一个实例。在ES中,引用类型是一种数据结构,用于将数据和功能组织在一起。它们也长被称为类,但这并不妥当。因为ES在技术层面上是一门面对对象的语言,但它并不具备传统的面…

使用Tape和Vue Test Utils编写快速的Vue单元测试
by Edd Yerburgh埃德耶堡(Edd Yerburgh) 使用Tape和Vue Test Utils编写快速的Vue单元测试 (Write blazing fast Vue unit tests with Tape and Vue Test Utils) Tape is the fastest framework for unit testing Vue components.磁带是用于Vue组件进行单元测试的最快框架。 I…

js去除数组中重复值
//第三种方法加强版 Array.prototype.distinctfunction(){ var sameObjfunction(a,b){ var tag true; if(!a||!b)return false; for(var x in a){ if(!b[x]) return false; if(typeof(a[x])object){ tagsameObj(a[x],b[x]); }else{ if(a[x]!b[x]) return false; } } return ta…

CXFServlet类的作用
CXFServlet是Apache CXF框架中的一个核心组件,用于处理HTTP请求并将它们转换为Web服务调用。通过配置CXFServlet,你可以轻松地部署和管理SOAP和RESTful Web服务。

了解jvm对编程的帮助_这是您对社会责任编程的了解
了解jvm对编程的帮助by ?? Anton de Regt由?? 安东德雷格 这是您对社会责任编程的了解 (This is what you need to know about Socially Responsible Programming) 您的才华比银行帐户中的零值多 (Your talent is worth more than lots of zeroes in your bank account) L…

解压和生成 system.imgdata.img ( ext4格式)
另一篇文章讲述了如何解压和生成system.img, 那是针对yaffs2格式的文件系统镜像。 目前越来越多的Android手机放弃了nand, 更多采用了emmc为内部存储设备。 以emmc为存储设备的android手机,其文件系统(/system,/data两个分区)一般采用ext4格式…

简单分析beyond作曲
本人绝对是业余的哈 业余到什么水平呢?正在练习爬格子,还是一个星期练几次那种 先说下《海阔天空》 6,5,4,3 1,2,3,4 简单是简单得不得了,声从低到高,然后再从…

1 OC 对象的本质(一个NSObject 对象占用的内存大小)
1 前言 目录 1 前言 2 一个NSObject占用多少内存 3 为什么呢 ? 4 如何在内存中看呢? OC 的面向对象都是基于C/C 的数据结构实现的 结构体 2 clang 命令转换成c 代码 clang -rewrite-objc main.m -o main.cpp 以上的命令是不分平台进行编译的&…

Xiki:一个开发人员寻求增强命令行界面的能力
by Craig Muth通过克雷格穆斯(Craig Muth) Xiki:一个开发人员寻求增强命令行界面的能力 (Xiki: one developer’s quest to turbocharge the command line interface) I was sitting with my friend Charles in a trendy cafe next to Golden Gate Park in San Fra…

2 OC 对象的本质(一个Student 占用的内存大小)
一 Student 占用的内存空间 补充: 1 成员变量占用字节的大小: 2 内存对齐的规则:结构体的内存大小必须是最大成员变量的内存的倍数。 一个 Student 类,继承自NSObject,有两个属性,首先要知道,int 类型占用…

jdk动态代理源码学习
最近用到了java的动态代理,虽然会用,但不了解他具体是怎么实现,抽空看看了看他的源码。 说到Java的动态代理就不能不说到代理模式,动态代理也就是多了一个’动态’两字,在《大话设计模式》中不是有这句话吗?“反射&…

20162313苑洪铭 第一周作业
20162313苑洪铭 20016-2017-2 《程序设计与数据结构》第1周学习总结 教材学习内容总结 本周观看教材绪论 主要在教我建立一个简单的java程序 内容是林肯的名言 虽然看起来很简单 但是实际上问题重重 总而言之 这一周全是在出现故障的 教材学习中的问题和解决过程 教材学习好像并…

测试驱动开发 测试前移_测试驱动的开发可能看起来是工作的两倍-但无论如何您都应该这样做...
测试驱动开发 测试前移by Navdeep Singh通过Navdeep Singh 测试驱动的开发可能看起来是工作的两倍-但无论如何您都应该这样做 (Test-driven development might seem like twice the work — but you should do it anyway) Isn’t Test Driven Development (TDD) twice the wor…

3 OC 属性和方法
1 OC 的属性的生成 interface Student:NSObject {publicint _no;int _age;}property (nonatomic,assign)int height;end 当我们使用property 的时候,那么系统会自动的在其内部生成个属性 xcrun -sdk iphoneos clang -arch arm64 -rewrite-objc main.m -o main.c…

ios绘图时的坐标处理
在iOS中,进行绘图操作时,一般主要是在UIView:drawRect中调用 UIGraphicsBeginImageContextWithOptions等一系列函数,有时候直接画图就行,比如UIImage的drawRect等,有时候需要进行稍微复杂的操作,比如颜色混…

mongoDB数据库操作工具库
/* Mongodb的数据库工具类 */ var client require(mongodb).MongoClient;function MongoUtil() { this.url"mongodb://localhost:27017/storage";//在本地新建数据库storage,此后插入的数据都在storage中 }MongoUtil.prototype.connectfunction(callback…